[Zope] Please Help! Wierd error that wasn't there before...
Dieter Maurer
dieter@handshake.de
Sun, 4 Nov 2001 19:56:08 +0100
Rob Foster writes:
> I had this working before... a user fills out a form which posts to a
> script which in turn creates a new user. Now, when a user is created in
> acl_users and when I click on it, I get the error below... I've tried
> changing the roles, moving the acl_users directory and changing the
> python script, all to no avail. The Zope user stuff is becoming really
> frustrating. I could use some help. Thanks in advance.
>
> BEGIN ERROR
> 'in ' requires character as left operand
> ....
> /Users/rfoster/Desktop/Zope-2.4.1-MOSX/lib/python/DocumentTemplate/DT_Util.
> py, line 231, in eval
> (Object: _vars['sequence-item'] in user.roles)
> (Info: _vars)
> File <string>, line 0, in ?
> TypeError: (see above)
When you created your new user, you passed the "roles" parameter
as a string. However, it must be a sequence...
The management page you are accessing above uses
"<some_role> in user.roles"
and this fails, because both "<some_role>" as well as
"user.roles" are strings.
Delete your user, fix your script (to pass a sequence of roles,
not a string) and try again.
Dieter