Group wont create

26 views
Skip to first unread message

Eduardo Cruz

unread,
Apr 17, 2014, 4:08:27 PM4/17/14
to web...@googlegroups.com
Hey!
When I try to create a new group with auth.add_group('Administrators', 'Administrators of the system') it return the id of the new group but the group is not created on the database.
but when I create an user and web2py create their group it got the next id, so I supposed that add_group is creating the group and the deleting it afterwards.
is there some reason why this is happening?

Anthony

unread,
Apr 17, 2014, 5:16:14 PM4/17/14
to web...@googlegroups.com
Where/how are you calling auth.add_group?

Eduardo Cruz

unread,
Apr 17, 2014, 5:30:35 PM4/17/14
to web...@googlegroups.com
from the console, it seems that if you have signature=True on auth it does not create groups when you are not logged in, if I make an user it works.


--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
---
You received this message because you are subscribed to a topic in the Google Groups "web2py-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/web2py/u1Nx2HubkxA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to web2py+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--

Anthony

unread,
Apr 17, 2014, 6:02:24 PM4/17/14
to web...@googlegroups.com
If you are in a shell, you need to call db.commit() to commit any changes to the database (this is not necessary in app code because that is handled automatically during a normal HTTP request).

Anthony


On Thursday, April 17, 2014 5:30:35 PM UTC-4, Eduardo Cruz wrote:
from the console, it seems that if you have signature=True on auth it does not create groups when you are not logged in, if I make an user it works.
On 17 April 2014 17:16, Anthony <abas...@gmail.com> wrote:
Where/how are you calling auth.add_group?


On Thursday, April 17, 2014 4:08:27 PM UTC-4, Eduardo Cruz wrote:
Hey!
When I try to create a new group with auth.add_group('Administrators', 'Administrators of the system') it return the id of the new group but the group is not created on the database.
but when I create an user and web2py create their group it got the next id, so I supposed that add_group is creating the group and the deleting it afterwards.
is there some reason why this is happening?

--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
---
You received this message because you are subscribed to a topic in the Google Groups "web2py-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/web2py/u1Nx2HubkxA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to web2py+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages