[Grok-dev] Mixing grok and ZCML registration for a directory resource
sylvain at infrae.com
Mon Mar 23 07:51:18 EDT 2009
Le Fri, 20 Mar 2009 12:07:25 +0900,
Martin Aspeli <optilude+lists at gmail.com> a écrit :
> I think I have an idea, actually, and it's weird.
> in five.grok.meta, there's a StaticResourcesGrokker that gets called
> dozens of times during startup. It registers resource directories for
> each package, looking for the 'static' sub-directory everywhere.
> I'd called my custom resourceDirectory ("foo" above) the same name as
> my package. Therefore, I think the two were conflicting (although I
> didn't get an error).
I think we can make them conflict, that's in five.grok I think there.
I will look at it as well, and if there is an issue it will be
great ... thanks anyway for reporting it.
> Surely, the StaticResourcesGrokker should do nothing if the path does
> not actually exist? A simple os.path.exists() should do the trick, I
Here that's the default behavior of Grok, that all static directories
are registered by default, so if you had the directory after, I think
it's already there. I think added a os.path.exists would be nice, but
that's change how Grok works.
We need to consult everybody here and ask them what they thinks about
it ... so everybody ?
Sylvain Viollon -- Infrae
t +31 10 243 7051 -- http://infrae.com
Hoevestraat 10 3033GC Rotterdam -- The Netherlands
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 188 bytes
Desc: not available
Url : http://mail.zope.org/pipermail/grok-dev/attachments/20090323/d73d4e3c/attachment.bin
More information about the Grok-dev