This is a bug!

I just fixed it in trunk.

Massimo

On Nov 4, 5:33 am, ruko <[EMAIL PROTECTED]> wrote:
> What's the reason for this error (@massimo's suggestion to a similar
> error: I can't add any empty lines: after saving the code in the web
> interface, the empty lines are gone.):
>
> Error traceback
> 1. Traceback (most recent call last):
> 2.   File "/var/lib/web2py/web2py/gluon/restricted.py", line 61, in
> restricted
> 3.     else: ccode=compile(code.replace('\r\n','\n'),layer,'exec')
> 4.   File "/var/lib/web2py/web2py/applications/Fallsammlung/models/
> db.py", line 29
> 5.
> #########################################################################
> 6.
> ^
> 7. SyntaxError: invalid syntax
> 8.
>
> In file: /var/lib/web2py/web2py/applications/Fallsammlung/models/db.py
> 1.
> #########################################################################
> 2. # This scaffolding model makes your app work on Google App Engine
> too   #
> 3.
> #########################################################################
> 4.
> 5. try:
> 6.     from gluon.contrib.gql import *         # if running on Google
> App Engine
> 7. except:
> 8.     db=SQLDB('mysql://dbuser:[EMAIL PROTECTED]:3306/
> Fallsammlung')         # if not, use SQLite or other DB
> 9. else:
> 10.     db=GQLDB()                              # connect to Google
> BigTable
> 11.     session.connect(request,response,db=db) # and store sessions
> there
> 12. #session.forget()                           # uncomment for no
> session at all
> 13.
> 14.
> #########################################################################
> 15. # Define your tables below, for
> example                                 #
> 16.
> #
> #
> 17. # >>>
> db.define_table('mytable',SQLField('myfield','string'))           #
> 18.
> #
> #
> 19. # Fields can be
> 'string','text','password','integer','double','booelan' #
> 20. #       'date','time','datetime','blob','upload', 'reference
> TABLENAME' #
> 21. # There is an implicit 'id integer autoincrement'
> field                 #
> 22. # Consult manual for more options, validators,
> etc.                     #
> 23.
> #
> #
> 24. # More API examples for
> controllers:                                    #
> 25.
> #
> #
> 26. # >>>
> db.mytable.insert(myfield='value')                                #
> 27. # >>>
> rows=db(db.mytbale.myfield=='value).select(db.mytable.ALL)        #
> 28. # >>> for row in rows: print row.id,
> row.myfield                        #
> 29.
> #########################################################################
--~--~---------~--~----~------------~-------~--~----~
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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to