Skip to content

Simple "Hello World" example on how to run Bottle on GAE using Python 2.7 WSGI Threadsafe.

License

Notifications You must be signed in to change notification settings

ganguera/bottle-gae-python27

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Bottle on GAE Python 2.7 WSGI Threadsafe

This is a simple "Hello World" example on how to run Bottle on Google App Engine using Python 2.7 WSGI Threadsafe.

Bottle ships with a "ready-to-use" GAE adapter, however, this adapter is specific for Python 2.5 which runs as CGI. If you want to run Bottle on Python 2.7 WSGI Threadsafe, you have to avoid running the server:

bottle.run(server='gae')

Instead, just instantiate the Bottle class and assign it to the local variable 'app':

app = Bottle(catchall=False)

By default, all exceptions other than HTTPResponse or HTTPError will result in a 500 Internal Server Error response, so they won’t crash your WSGI server. You can turn off this behavior to handle exceptions in your middleware by setting bottle.app().catchall to False.

About

Simple "Hello World" example on how to run Bottle on GAE using Python 2.7 WSGI Threadsafe.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages