GithubHelp home page GithubHelp logo

googlecloudplatform / appengine-guestbook-python Goto Github PK

View Code? Open in Web Editor NEW
238.0 108.0 329.0 444 KB

Guestbook is an example application showing basic usage of Google App Engine

Home Page: https://developers.google.com/appengine/docs/python/gettingstartedpython27/

License: Apache License 2.0

Python 59.60% HTML 29.93% Makefile 10.47%

appengine-guestbook-python's Introduction

Guestbook

Guestbook is an example application showing basic usage of Google App Engine. Users can read & write text messages and optionally log-in with their Google account. Messages are stored in App Engine (NoSQL) High Replication Datastore (HRD) and retrieved using a strongly consistent (ancestor) query.

Products

Language

APIs

Dependencies

E2E Test for this sample app

A Makefile is provided to deploy and run the e2e test.

To run:

 export GAE_PROJECT=your-project-id
 make

To manually run, install the requirements

pip install -r e2e/requirements-dev.txt

Set the environment variable to point to your deployed app:

export GUESTBOOK_URL="http://guestbook-test-dot-useful-temple-118922.appspot.com/"

Finally, run the test

python e2e/test_e2e.py

Deploy to App Engine

Deploy this from a terminal with the Google Cloud SDK installed.

The index.yaml needs to be built first by running:

 gcloud app deploy index.yaml

Wait for indexes to build in datastore then run:

 gcloud app deploy app.yaml

appengine-guestbook-python's People

Contributors

ajyoon avatar brycebuffaloe avatar danholevoet avatar dependabot[bot] avatar elliotwaite avatar foleyj avatar fredsa avatar gainward avatar johndmulhausen avatar meredithslota avatar mtn avatar proppy avatar rsamuelklatchko avatar timgates42 avatar tmatsuo avatar waprin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

appengine-guestbook-python's Issues

internal server error

I want to be friends with app engine but so far no luck. please help.

This is the error message

internal_server_error

This is the input used to generate that message

command_line

Internal Server Error

I have deployed the application according to the tutorial : https://cloud.google.com/shell/docs/quickstart#use_your_home_directory

and getting error when I am acceing the appliation in browser:
[Internal Server Error
The server has either erred or is incapable of performing the requested operation.
Traceback (most recent call last):
File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1535, in call
rv = self.handle_exception(request, response, e)
File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1529, in call
rv = self.router.dispatch(request, response)
File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1278, in default_dispatcher
return route.handler_adapter(request, response)
File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1102, in call
return handler.dispatch()
File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 572, in dispatch
return self.handle_exception(e, self.app.debug)
File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 570, in dispatch
return method(_args, *_kwargs)
File "/base/data/home/apps/s~aoa-pak/20160616t115013.393542445044468413/guestbook.py", line 72, in get
greetings = greetings_query.fetch(10)
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/utils.py", line 160, in positional_wrapper
return wrapped(_args, *_kwds)
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/query.py", line 1203, in fetch
return self.fetch_async(limit, **q_options).get_result()
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/tasklets.py", line 383, in get_result
self.check_success()
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/tasklets.py", line 427, in _help_tasklet_along
value = gen.throw(exc.class, exc, tb)
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/query.py", line 980, in _run_to_list
batch = yield rpc
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/tasklets.py", line 513, in _on_rpc_completion
result = rpc.get_result()
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/api/apiproxy_stub_map.py", line 613, in get_result
return self.__get_result_hook(self)
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/datastore/datastore_query.py", line 2921, in __query_result_hook
yaml_index=yaml, xml_index=xml)
NeedIndexError: The index for this query is not ready to serve. See the Datastore Indexes page in the Admin Console.
The suggested index for this query is:

  • kind: Greeting
    ancestor: yes
    properties:
    • name: date
      direction: desc

]

Bootstrap error

When resizing a browser window the navbar behaves strangely - above 980 pixels wide there is a login button, but below 980 the entire navbar moves down, the login button disappears, replaced by a right toolbar expand icon that does nothing.

Bootstrap lint https://github.com/twbs/bootlint/wiki reports a number of warnings and one error: E013 - row children must be columns. Index.html has a container div with a row div, but the items under the rows (greetings, form, and logout button) are not in column spans. I don't know if that error has anything to do with the strange navbar behavior, but just on general principles the page should lint cleanly.

ImportError: No module named fileutils

When i started the local server to run helloworld-example under google_appengine_1.9.7 on ubuntu 13.10, i got errors as below:

INFO     2014-07-19 14:27:00,047 sdk_update_checker.py:242] Checking for updates to the SDK.
INFO     2014-07-19 14:27:01,203 sdk_update_checker.py:270] The SDK is up to date.
WARNING  2014-07-19 14:27:01,217 simple_search_stub.py:1090] Could not read search indexes from /tmp/appengine.helloworld.andy/search_indexes
INFO     2014-07-19 14:27:01,541 api_server.py:171] Starting API server at: http://localhost:47778
WARNING  2014-07-19 14:27:01,542 file_watcher.py:110] Could not create InotifyFileWatcher; falling back to MTimeFileWatcher: [Errno 24] EMFILE
INFO     2014-07-19 14:27:01,544 api_server.py:583] Applying all pending transactions and saving the datastore
INFO     2014-07-19 14:27:01,544 api_server.py:586] Saving search indexes
Traceback (most recent call last):
  File "google_appengine/dev_appserver.py", line 82, in <module>
  File "google_appengine/dev_appserver.py", line 78, in _run_file
  File "/home/andy/tmpworld/cloudapp/gae/google_appengine/google/appengine/tools/devappserver2/devappserver2.py", line 961, in <module>
  File "/home/andy/tmpworld/cloudapp/gae/google_appengine/google/appengine/tools/devappserver2/devappserver2.py", line 957, in main
  File "/home/andy/tmpworld/cloudapp/gae/google_appengine/google/appengine/tools/devappserver2/devappserver2.py", line 774, in stop
  File "/home/andy/tmpworld/cloudapp/gae/google_appengine/google/appengine/tools/devappserver2/api_server.py", line 174, in quit
  File "/home/andy/tmpworld/cloudapp/gae/google_appengine/google/appengine/tools/devappserver2/api_server.py", line 587, in cleanup_stubs
  File "/home/andy/tmpworld/cloudapp/gae/google_appengine/google/appengine/api/search/simple_search_stub.py", line 1056, in Write
  File "/usr/lib/python2.7/tempfile.py", line 308, in mkstemp
  File "/usr/lib/python2.7/tempfile.py", line 236, in _mkstemp_inner
  File "/usr/lib/python2.7/tempfile.py", line 138, in next
  File "/usr/lib/python2.7/tempfile.py", line 128, in rng
  File "/usr/lib/python2.7/random.py", line 97, in __init__
  File "/usr/lib/python2.7/random.py", line 111, in seed
OSError: [Errno 24] Too many open files
Error in sys.excepthook:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/apport_python_hook.py", line 64, in apport_excepthook
ImportError: No module named fileutils

i'm a newer to GAE. And after googled the errors all day, i still had no idea how to deal with it. Anyone help?

A minor typo (maybe)

I am a beginner at python so don't know for sure if its a typo or not .
In code of guestbook.py
application = webapp2.WSGIApplication([
('/', MainPage),
('/sign', Guestbook),
], debug=True)

Didn't it look it has extra comma after Guestbook.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.