t4

GAE problem in T4 db.py

Bug #516310 reported by cfhowes
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
t4
New
Undecided
Unassigned

Bug Description

db.py does not run on GAE due to an improper query. the fix is shown in this diff:

hg diff web2py/applications/t4/models/db.py
diff -r 1371064ff531 web2py/applications/t4/models/db.py
--- a/web2py/applications/t4/models/db.py Tue Feb 02 14:45:02 2010 -0800
+++ b/web2py/applications/t4/models/db.py Tue Feb 02 14:45:50 2010 -0800
@@ -120,7 +120,7 @@
                    body=open(STYLES,'rb').read(), saved_by=author)

-if not db(db.auth_group.id>2).count() and auth.user:
+if not (db(db.auth_group.id>0).count() > 2) and auth.user:
     group_id = auth.add_group(role='administrator')
     auth.add_membership(group_id)

Revision history for this message
Massimo (mdipierro) wrote : Re: [Bug 516310] [NEW] GAE problem in T4 db.py

Thank you!

On Feb 2, 2010, at 4:49 PM, cfhowes wrote:

> Public bug reported:
>
> db.py does not run on GAE due to an improper query. the fix is
> shown in
> this diff:
>
> hg diff web2py/applications/t4/models/db.py
> diff -r 1371064ff531 web2py/applications/t4/models/db.py
> --- a/web2py/applications/t4/models/db.py Tue Feb 02 14:45:02 2010
> -0800
> +++ b/web2py/applications/t4/models/db.py Tue Feb 02 14:45:50 2010
> -0800
> @@ -120,7 +120,7 @@
> body=open(STYLES,'rb').read(), saved_by=author)
>
>
> -if not db(db.auth_group.id>2).count() and auth.user:
> +if not (db(db.auth_group.id>0).count() > 2) and auth.user:
> group_id = auth.add_group(role='administrator')
> auth.add_membership(group_id)
>
> ** Affects: t4
> Importance: Undecided
> Status: New
>
> --
> GAE problem in T4 db.py
> https://bugs.launchpad.net/bugs/516310
> You received this bug notification because you are the registrant for
> t4.
>
> Status in t4: New
>
> Bug description:
> db.py does not run on GAE due to an improper query. the fix is
> shown in this diff:
>
> hg diff web2py/applications/t4/models/db.py
> diff -r 1371064ff531 web2py/applications/t4/models/db.py
> --- a/web2py/applications/t4/models/db.py Tue Feb 02 14:45:02 2010
> -0800
> +++ b/web2py/applications/t4/models/db.py Tue Feb 02 14:45:50 2010
> -0800
> @@ -120,7 +120,7 @@
> body=open(STYLES,'rb').read(), saved_by=author)
>
>
> -if not db(db.auth_group.id>2).count() and auth.user:
> +if not (db(db.auth_group.id>0).count() > 2) and auth.user:
> group_id = auth.add_group(role='administrator')
> auth.add_membership(group_id)
>
>

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.