<s> """<STR_LIT>""" <EOL> import os <EOL> import MySQLdb <EOL> import webapp2 <EOL> CLOUDSQL_PROJECT = '<STR_LIT>' <EOL> CLOUDSQL_INSTANCE = '<STR_LIT>' <EOL> class MainPage ( webapp2 . RequestHandler ) : <EOL> def get ( self ) : <EOL> self . response . headers [ '<STR_LIT:Content-Type>' ] = '<STR_LIT>' <EOL> if os . getenv ( '<STR_LIT>' , '<STR_LIT>' ) . startswith ( '<STR_LIT>' ) : <EOL> db = MySQLdb . connect ( <EOL> unix_socket = '<STR_LIT>' . format ( <EOL> CLOUDSQL_PROJECT , <EOL> CLOUDSQL_INSTANCE ) , <EOL> user = '<STR_LIT:root>' ) <EOL> else : <EOL> db = MySQLdb . connect ( host = '<STR_LIT:localhost>' , user = '<STR_LIT:root>' ) <EOL> cursor = db . cursor ( ) <EOL> cursor . execute ( '<STR_LIT>' ) <EOL> for r in cursor . fetchall ( ) : <EOL> self . response . write ( '<STR_LIT>' . format ( r ) ) <EOL> app = webapp2 . WSGIApplication ( [ <EOL> ( '<STR_LIT:/>' , MainPage ) , <EOL> ] , debug = True ) </s>
