[Zope-dev] why cant i rename an object from an external method

Shane Hathaway shane@digicool.com
Thu, 28 Sep 2000 23:26:05 -0400


Andy McKay wrote:
> 
> Heres a treat. I'm trying to write an external method to rename objects. I
> have approx 10,000 to rename so a script would be nice. No problem I
> thought, imitate a forms manage_renameObject and CopySupport.py can do the
> work.
> 
> Rename works fine from the web form, but not from a script.
> (ASPNTools.getsomeobjectsfromstring returns a bunch of objects, Ive tried
> replicating this with resolve_url and get different namespace error, could
> this be a clue?).

I would try using _delObject and _setObject instead. 
manage_renameObject() does some security checks that don't apply in your
case.

Shane