Hi Joe, On Sep 5, 2006, at 11:52 PM, Joe wrote:
>> tg-admin sql create -c dev.cfg Hmm, you shouldn't need to specify -c dev.cfg if you're in the right directory. > Using database URI postgres://[EMAIL PROTECTED]/tg > Traceback (most recent call last): > File "/usr/local/bin/tg-admin", line 7, in ? > sys.exit( > File > "/usr/local/lib/python2.4/site-packages/TurboGears-0.8.9-py2.4.egg/ > turbogears/command/__init__.py", > line 186, in main > command.run() > File > "/usr/local/lib/python2.4/site-packages/TurboGears-0.8.9-py2.4.egg/ > turbogears/command/__init__.py", > line 106, in run > command.the_runner.run(sys.argv) > File > "/usr/local/lib/python2.4/site-packages/SQLObject-0.7.1dev_r1457- > py2.4.egg/sqlobject/manager/command.py", > line 102, in run > runner.run() > File > "/usr/local/lib/python2.4/site-packages/SQLObject-0.7.1dev_r1457- > py2.4.egg/sqlobject/manager/command.py", > line 233, in run > self.command() > File > "/usr/local/lib/python2.4/site-packages/SQLObject-0.7.1dev_r1457- > py2.4.egg/sqlobject/manager/command.py", > line 542, in command > for soClass in self.classes(require_some=True): > File > "/usr/local/lib/python2.4/site-packages/SQLObject-0.7.1dev_r1457- > py2.4.egg/sqlobject/manager/command.py", > line 255, in classes > conn = self.connection() > File > "/usr/local/lib/python2.4/site-packages/SQLObject-0.7.1dev_r1457- > py2.4.egg/sqlobject/manager/command.py", > line 316, in connection > return sqlobject.connectionForURI(self.options.connection_uri) > File > "/usr/local/lib/python2.4/site-packages/SQLObject-0.7.1dev_r1457- > py2.4.egg/sqlobject/dbconnection.py", > line 924, in connectionForURI > assert self.instanceNames.has_key(uri), \ > AssertionError: No SQLObject driver exists under the name dev.cfg > > I traced the execution path and it seems that TG command/__init__ > tacks > on the dburi with a -c to the argv passed to sqlobject.manager's > command. Then apparently CommandCreate() calls the standard_parser() > which adds it to self.options.connection_uri. So, as you said > everything ought to work. Actually, that doesn't sound right at all. The dburi needs to come from the config file, but it shouldn't come directly from the -c command line option. There was a relatively recent change in behavior to fix things so that tg-admin commands (like the toolboxes) ran under their own, sane configs but still got the dburi from your project. t looks like something isn't quite right with that. Kevin --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "TurboGears" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/turbogears -~----------~----~----~----~------~----~------~--~---

