Underscoring Inaugural Address
Hello there Zopatistas, In my inaugural post, I should like to enquire about getting to a url like so: http://myzopeserver.something.clever/a/path/to/a/file/named/__init__.py Getting to the object "__init__.py" is difficult (it acts like it doesn't exist.) Is there a way to muck about with getattr, traversal, or something related so that, for a particular kind of object (eg with a particular attribute), Zope ignores the "cannot start with a '_' " rule? I notice that the cvs.zope.org seems to transparently solve this problem, so presumably (if said interface is on a zope instance), this is solvable. Cheers, Dan
--On Mittwoch, 11. Mai 2005 15:00 Uhr -0400 Dan Pozmanter <dan@siteworx.com> wrote:
Is there a way to muck about with getattr, traversal, or something related so that, for a particular kind of object (eg with a particular attribute), Zope ignores the "cannot start with a '_' " rule?
I think it is a bad idea trying to be tricky :-)
I notice that the cvs.zope.org seems to transparently solve this problem, so presumably (if said interface is on a zope instance), this is solvable.
cvs.zope.org does not run on Zope :-) -aj
Dan Pozmanter wrote:
Hello there Zopatistas,
In my inaugural post, I should like to enquire about getting to a url like so: http://myzopeserver.something.clever/a/path/to/a/file/named/__init__.py
Getting to the object "__init__.py" is difficult (it acts like it doesn't exist.)
Is there a way to muck about with getattr, traversal, or something related so that, for a particular kind of object (eg with a particular attribute), Zope ignores the "cannot start with a '_' " rule?
I notice that the cvs.zope.org seems to transparently solve this problem, so presumably (if said interface is on a zope instance), this is solvable.
Probably, but it would be difficult. I don't even know enough about screwing with traversal to advise. By "file" what exactly do you mean? I wonder if LocalFS deals with this problem? If it allows _filenames, perhaps you can stead something from there. --jcc -- "Building Websites with Plone" http://plonebook.packtpub.com/
On Wed, May 11, 2005 at 03:00:02PM -0400, Dan Pozmanter wrote:
Hello there Zopatistas,
In my inaugural post, I should like to enquire about getting to a url like so: http://myzopeserver.something.clever/a/path/to/a/file/named/__init__.py
Getting to the object "__init__.py" is difficult (it acts like it doesn't exist.)
Objects whose names begin with underscores are not "publishable." The code is in lib/python/ZPublisher/BaseRequest.py and there is no easy way to override this behavior. -- Paul Winkler http://www.slinkp.com
participants (4)
-
Andreas Jung -
Dan Pozmanter -
J Cameron Cooper -
Paul Winkler