Hi,

I'm using Django 1.3 with the "stock" admin interface. No customizations.  
In the Site Administration, I can add new users. However, if I try to add a 
group I get the Add Group screen, with the fields for name and selection of 
permissions, and the three save buttons at the bottom ("Save and add", 
"Save and edit", "Save").  After filling out the form, and clicking any of 
the saves I end up at:

ValueError at /admin/auth/group/add/ 

'Group' instance needs to have a primary key value before a many-to-many 
relationship can be used.

 Request Method: POST  Request URL: 
http://.../resources/admin/auth/group/add/  Django Version: 1.3.1  Exception 
Type: ValueError  Exception Value: 

'Group' instance needs to have a primary key value before a many-to-many 
relationship can be used.

 Exception Location: 
/usr/lib/python2.7/dist-packages/django/db/models/fields/related.py 
in __init__, line 493  Python Executable: /usr/bin/python  Python Version: 
2.7.3  Python Path: 

['/usr/lib/python2.7',
 '/usr/lib/python2.7/plat-linux2',
 '/usr/lib/python2.7/lib-tk',
 '/usr/lib/python2.7/lib-old',
 '/usr/lib/python2.7/lib-dynload',
 '/usr/local/lib/python2.7/dist-packages',
 '/usr/lib/python2.7/dist-packages',
 '/usr/lib/python2.7/dist-packages/HTMLgen',
 '/usr/lib/python2.7/dist-packages/PIL',
 '/usr/lib/pymodules/python2.7/gtk-2.0',
 '/usr/lib/python2.7/dist-packages/gst-0.10',
 '/usr/lib/python2.7/dist-packages/gtk-2.0',
 '/usr/lib/pymodules/python2.7',
 '/usr/lib/python2.7/dist-packages/ubuntu-sso-client',
 '/usr/lib/python2.7/dist-packages/ubuntuone-client',
 '/usr/lib/python2.7/dist-packages/ubuntuone-control-panel',
 '/usr/lib/python2.7/dist-packages/ubuntuone-couch',
 '/usr/lib/python2.7/dist-packages/ubuntuone-installer',
 '/usr/lib/python2.7/dist-packages/ubuntuone-storage-protocol',
 '/usr/lib/python2.7/dist-packages/wx-2.6-gtk2-unicode',
 '/home/.../Django']


However, this works:

$ psql django
INSERT INTO auth_group (name) VALUES ('qwert');

and I can then use the interface to edit the permissions for the group.  
(So far, "qwert" is the only group in the system.)  Adding users to group 
"qwert" works, but the permissions appear to be ignored.

Any idea what's hosed?

Thanks!


-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/django-users/-/SU9VRRCRVqwJ.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to