-----Original Message----- From: Tony McDonald [mailto:tony.mcdonald@ncl.ac.uk] Sent: Monday, September 13, 1999 11:27 AM To: Zope List Subject: Re: [Zope] Python Methods? (don't work for me...)
same here.
I entered REQUEST, urllib into the parameter list, and got the same message.
For the moment, you must pass the module in from an external method or from DTML (in the case of urllib, this only works from an external method). Sorta defeats the purpose but proves the concept and works for debugging purposes. Evan, what are your ideas on a '_' like namespace where you provide some handy dandy modules? Could very much increase the usability of PythonMethods for the short term until you work out importing. -Michel
Michel Pelletier wrote:
Evan, what are your ideas on a '_' like namespace where you provide some handy dandy modules? Could very much increase the usability of PythonMethods for the short term until you work out importing.
Since my objective is to make PythonMethods exactly as secure as DTML Methods, I don't want to provide *anything* that they don't. External Methods are a good way to give controlled access to additional modules like this. I plan to enable 'import' in the same way I enabled 'print', by which I mean the command will be usable, but will work differently than in standard Python code. Most likely, 'import' will be bent into a tool for accessing other objects in the ZODB hierarchy. Despite that, on my personal site, I use a teeny little Product which inserts urllib, base64, and some builtins like 'list' and 'map' into the standard namespace object. I'm the only authorized user, so it seems safe :-)
I'm still getting weirdness with the 0.1.1 python methods under win32. I see the wrong icon(folder) for my previous pythonmethods and get messages about unpickleable objects each time I change directory. Has anyone else seen these debug messages or is it just me. -- Robin Becker
In article <u8GKcEAZeh33EwKL@jessikat.demon.co.uk>, Robin Becker <robin@jessikat.demon.co.uk> writes
I'm still getting weirdness with the 0.1.1 python methods under win32. I see the wrong icon(folder) for my previous pythonmethods and get messages about unpickleable objects each time I change directory. Has anyone else seen these debug messages or is it just me. OK I have got this working again. I missed the delete old PythonMethods warning. Seems odd that these could affect things in other directories. -- Robin Becker
participants (3)
-
Evan Simpson -
Michel Pelletier -
Robin Becker