On Mar 7, 2011, at 11:33 PM, Plumo wrote:
> I have the following listing in routes:
> ('/robots.txt', '/cms/static/robots.txt')
> 
> This lets me access /robots.txt on my local computer, but returns "invalid 
> request" when I upload this to GAE. Are there meant to be any differences 
> when using routes on GAE?
> 
> I can access /cms/static/robots.txt on both local and GAE.

GAE serves static files directly, and I don't think they end up in the location 
that web2py expects. So the path that routes generates ends up being wrong. 
When you access /cms/static/robots.txt, GAE is fetching it for you.

You need to add something like this to your app.yaml:

- url: /favicon.ico
  static_files: applications/cms/static/favicon.ico
  upload: applications/cms/static/favicon.ico

- url: /robots.txt
  static_files: applications/cms/static/robots.txt
  upload: applications/cms/static/robots.txt

Reply via email to