On Wed, Dec 31, 2008 at 11:49 AM, Mark Ramm <[email protected]> wrote:
>
> What version are you using?
>
The b1 is using this correct?
easy_install -i http://www.turbogears.org/2.0/downloads/current/index
tg.devtools
I do:
paster quickstart myapp
Enter package name [myapp]:
Do you need authentication and authorization in this project? [yes] no
tginfo:
TurboGears2 Templates
* turbogears2 (tg.devtools 2.0b1dev-r5993)
TurboGears2 Commands
* migrate (tg.devtools 2.0b1dev-r5993)
* crud (tg.devtools 2.0b1dev-r5993)
* quickstart (tg.devtools 2.0b1dev-r5993)
* shell (TurboGears2 2.0b1)
* serve (TurboGears2 2.0b1)
for some reason I get an error on python2.5, but not on python2.4
Here is what ends up in my root.py:
class RootController(BaseController):
admin = Catwalk(DBSession, metadata)
error = ErrorController()
I'm attaching a patch to devtools that fixes it. I assume that
errorcontroller should not be imported.
I am not sure why it only happens on py2.5.
Thanks,
Lucas
> errorController should not be imported in b1, and in the latest trunk
> it is imported properly.
>
> On Tue, Dec 30, 2008 at 11:40 PM, Lukasz Szybalski <[email protected]>
> wrote:
>>
>> Hello,
>>
>> Just an fyi, I just run the quickstarted non-authenticated apps and
>> the quickstart template has some errors. It works just find in
>> authenitcation required apps do.
>>
>>
>> 1. After quickstart-ed, there is an indent error on line 11,
>>
>> File
>> '/home/lucas/tmp/tg2b2ENV/lib/python2.5/site-packages/TurboGears2-2.0b1-py2.5.egg/tg/wsgiapp.py',
>> line 38 in find_controller
>> __import__(full_module_name)
>> IndentationError: unexpected indent (root.py, line 11)
>>
>>
>> 2. and errorController is not imported.
>>
>> File '/home/lucas/tmp/tg2b2app/tg2b2app/controllers/root.py', line 9 in
>> <module>
>> class RootController(BaseController):
>> File '/home/lucas/tmp/tg2b2app/tg2b2app/controllers/root.py', line 11
>> in RootController
>> error = ErrorController()
>> NameError: name 'ErrorController' is not defined
>>
>> Lucas
>>
>>
>>
>> --
>> How to create python package?
>> http://lucasmanual.com/mywiki/PythonPaste
>> Bazaar and Launchpad
>> http://lucasmanual.com/mywiki/Bazaar
>>
>> >
>>
>
>
>
> --
> Mark Ramm-Christensen
> email: mark at compoundthinking dot com
> blog: www.compoundthinking.com/blog
>
> >
>
--
How to create python package?
http://lucasmanual.com/mywiki/PythonPaste
Bazaar and Launchpad
http://lucasmanual.com/mywiki/Bazaar
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears Trunk" 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-trunk?hl=en
-~----------~----~----~----~------~----~------~--~---
Index: devtools/templates/turbogears/+package+/controllers/root.py_tmpl
===================================================================
--- devtools/templates/turbogears/+package+/controllers/root.py_tmpl (revision 5996)
+++ devtools/templates/turbogears/+package+/controllers/root.py_tmpl (working copy)
@@ -23,8 +23,8 @@
{{if auth == "sqlalchemy"}}
admin = SecuredCatwalk(DBSession, metadata)
secc = SecureController()
+ error = ErrorController()
{{endif}}
- error = ErrorController()
@expose('{{package}}.templates.index')
def index(self):