I agree this should work. Tito, would you confirm that after you do an 'update_indexes' then login to appspot.com, that 'missing' index is listed and all the indexes say 'serving'?
The easiest way to test this is to add the orderby's back in to your app, manually exercise the development app which updates index.yaml, then do one 'appcfg.py update web2py/', login to appspot.com and view the index building status. Once all indexes say serving, then try hitting your app. Furthermore, to verify your indexes on the local development server, launch your app like this: 'dev_appserver.py --require_indexes web2py/' which will raise an error locally if your app tries to use an index that is not listed in index.yaml. http://code.google.com/appengine/docs/python/tools/devserver.html#Command_Line_Arguments Robin On Jun 7, 12:13 pm, mdipierro <mdipie...@cs.depaul.edu> wrote: > What type of field are you ordering by? > This should work. Can Robin confirm? > > Massimo > > On Jun 7, 11:23 am, Tito Garrido <titogarr...@gmail.com> wrote: > > > Using update_indexes didn't work... I had to remove all "orderby"s from > > "selects". > > > Is it a bug? > > > Thanks! > > > Tito > > > On Sun, Jun 7, 2009 at 11:18 AM, Tito Garrido <titogarr...@gmail.com> wrote: > > > Thank you folks, > > > > I'll try appcfg.py update_indexes myapp/ to test... localy it works > > > perfectly. > > > > I'll keep you in touch about it! > > > > Thanks Again > > > > Tito > > > > On Sat, Jun 6, 2009 at 6:53 PM, Robin B <robi...@gmail.com> wrote: > > > >> The easiest way to fix this is to exercise your app on the development > > >> server, (use the query that needs that missing index) which will add > > >> the missing index to the generated index.yaml. The next time you > > >> update/deploy your index.yaml to production, GAE will 'build' the new > > >> index which takes time. Until the new index is added, any query that > > >> trys to use it will throw an exception. You can see the index > > >> building progress if you login to appspot.com. > > > >> The safest way to add a new index is to write tests that exercise your > > >> app in development, so index.yaml is autogenerated. Then deploy your > > >> indexes with: > > > >> appcfg.py update_indexes myapp/ > > > >>http://code.google.com/appengine/docs/python/tools/uploadinganapp.htm... > > > >> Once you see that the indexes are all 'serving' (built), then deploy > > >> your app code with: > > > >> appcfg.py update myapp/ > > > >> Robin > > > >> On Jun 6, 1:46 pm, Hans Donner <hans.don...@pobox.com> wrote: > > >> > running locally works fine? > > >> > did you check index.yaml? > > > >> > On Sat, Jun 6, 2009 at 8:41 PM, Tito Garrido<titogarr...@gmail.com> > > >> wrote: > > >> > > Hi Folks, > > > >> > > I've been receiving Index Errors when I try to run my web2py on gae > > >> > > application: > > > >> > > 189.115.246.131 - - [06/Jun/2009:11:37:39 -0700] "GET / HTTP/1.1" 500 > > >> 251 > > >> > > " > > >>http://appengine.google.com/deployment?&app_id=tito-garrido&version_i..." > > >> > > "Mozilla/5.0 (Windows; U; Windows NT 5.1; pt-BR; rv:1.9.0.10) > > >> > > Gecko/2009042316 Firefox/3.0.10,gzip(gfe)" > > >> > > "1.latest.tito-garrido.appspot.com" > > > >> > > W 06-06 11:37AM 38.505 > > > >> > > no file locking > > > >> > > D 06-06 11:37AM 39.045 > > > >> > > no sqlite3 or mysqlite2.dbapi2 driver > > > >> > > D 06-06 11:37AM 39.047 > > > >> > > no MySQLdb driver > > > >> > > D 06-06 11:37AM 39.049 > > > >> > > no psycopg2 driver > > > >> > > D 06-06 11:37AM 39.051 > > > >> > > no cx_Oracle driver > > > >> > > D 06-06 11:37AM 39.054 > > > >> > > no MSSQL/DB2 driver > > > >> > > D 06-06 11:37AM 39.058 > > > >> > > no kinterbasdb driver > > > >> > > D 06-06 11:37AM 39.062 > > > >> > > no informixdb driver > > > >> > > D 06-06 11:37AM 39.065 > > > >> > > no zxJDBC driver > > > >> > > W 06-06 11:37AM 39.091 > > > >> > > unable to import dbhash > > > >> > > W 06-06 11:37AM 39.181 > > > >> > > unable to import wsgiserver > > > >> > > E 06-06 11:37AM 39.420 > > > >> > > Traceback (most recent call last): > > >> > > File > > > >> "/base/data/home/apps/tito-garrido/1.334017845210245114/gluon/restricted.py", > > >> > > line 107, in restricted > > >> > > exec ccode in environment > > > >> > > File > > > >> "/base/data/home/apps/tito-garrido/1.334017845210245114/applications/init/controllers/default.py:index", > > >> > > line 144, in <module> > > >> > > File > > > >> "/base/data/home/apps/tito-garrido/1.334017845210245114/gluon/globals.py", > > >> > > line 97, in <lambda> > > > >> > > self._caller = lambda f: f() > > >> > > File > > > >> "/base/data/home/apps/tito-garrido/1.334017845210245114/applications/init/controllers/default.py:index", > > >> > > line 58, in index > > >> > > File > > > >> "/base/data/home/apps/tito-garrido/1.334017845210245114/gluon/contrib/gql.py", > > >> > > line 736, in select > > > >> > > for item in items: > > >> > > File > > >> "/base/python_lib/versions/1/google/appengine/ext/db/__init__.py", > > >> > > line 1372, in __iter__ > > >> > > return self.run() > > >> > > File > > >> "/base/python_lib/versions/1/google/appengine/ext/db/__init__.py", > > >> > > line 1360, in run > > > >> > > iterator = self._get_query().Run() > > >> > > File > > >> "/base/python_lib/versions/1/google/appengine/api/datastore.py", line > > >> > > 886, in Run > > >> > > return self._Run() > > >> > > File > > >> "/base/python_lib/versions/1/google/appengine/api/datastore.py", line > > >> > > 913, in _Run > > > >> > > str(exc) + '\nThis query needs this index:\n' + yaml) > > >> > > NeedIndexError: no matching index found. > > >> > > This query needs this index: > > >> > > - kind: product > > >> > > properties: > > >> > > - name: featured > > >> > > - name: name > > > >> > > direction: desc > > > >> > > Anybody has a clue of what should I do to fix it? > > > >> > > Thanks! > > > >> > > Tito > > > >> > > -- > > > >> > > Linux User #387870 > > >> > > .........____ > > >> > > .... _/_õ|__| > > >> > > ..º[ .-.___.-._| . . . . > > >> > > .__( o)__( o).:_______ > > >> > > Sent from Salvador, BA, Brazil > > > > -- > > > > Linux User #387870 > > > .........____ > > > .... _/_õ|__| > > > ..º[ .-.___.-._| . . . . > > > .__( o)__( o).:_______ > > > -- > > > Linux User #387870 > > .........____ > > .... _/_õ|__| > > ..º[ .-.___.-._| . . . . > > .__( o)__( o).:_______ > > Sent from Salvador, BA, Brazil --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "web2py Web Framework" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~----------~----~----~----~------~----~------~--~---