[ZCM] [ZC] 1173/ 2 Comment "ids should allow all characters vaild in a URL"

Collector: Zope Bugs, Features, and Patches ... zope-coders-admin at zope.org
Mon Jan 12 05:26:24 EST 2004


Issue #1173 Update (Comment) "ids should allow all characters vaild in a URL"
 Status Pending, Zope/bug medium
To followup, visit:
  http://zope.org/Collectors/Zope/1173

==============================================================
= Comment - Entry #2 by ajung on Jan 12, 2004 5:26 am

There is really no good reasons why URL-encoded Ids
should be allowed. Allowing new characters as Ids raised
several times problems that had to be fixed in other code.
Your problem appears to me that you should decode your names
*before* creating new objects. So I tend to reject this issue.
________________________________________
= Request - Entry #1 by janwilhelm on Jan 11, 2004 4:52 pm

Zope does not allow me to create an object with an id such as "a%20simple%20test". Ironically, it gives me the message::

  Error Type: Bad Request
  Error Value: The id "a%20simple%20test" contains characters illegal in URLs.

However, "a%20simple%20test" is perfectly valid as part of a URL. By using an oversimplified and too strict test in OFS/ObjectManager (regexp bad_id), Zope wastes the possibility of using url_quote to create valid, unique, readable ids from arbitrary strings using the standard method.

bad_id should be modified to only eliminate strings that are really illegal as part of an URL.

Thanks,

Jan

==============================================================




More information about the Zope-Collector-Monitor mailing list