[Zope3-dev] Notations for paths (was comments on Guido's diary)

Martijn Faassen faassen@vet.uu.nl
Fri, 20 Dec 2002 18:18:08 +0100


Jim Fulton wrote:
[snip]
> >I would recommend that, for correctness, code always uses the 
> >convenience functions in Zope.App.Traversing.
> 
> Yes.

In that case, I'd say make it a class and be done with it. That way
everybody will always use the 'convenience functions', as they will
be methods.

My second best vote would be to make string paths (not tuples) the
way to indicate locations; at least there's a precedent there with filepaths.
Though in the case of filesystem paths, we do see it happening over
and over again that people use '/' instead of 'os.sep' and + instead of
'os.path.join'. This may be an instructive lesson and a good argument
for really using a class. :)

Regards,

Martijn