[z3-five] Some problems I found porting Silva views
Guido Wesdorp
guido at infrae.com
Tue Jun 22 17:58:32 MEST 2004
Hi!
I did some work to get some Silva views to work in Five, and overall I
was surprised about how easy it was. However, I did run into some
unexpected problems:
1. in tal there's this repeat thing, which allows to ask properties
about a certain repeat. For instance, if there's a 'tal:repeat="foo
bar"' somewhere, you can use 'repeat/foo/number' to get the index of the
current processing element. These properties, however, are unaccessible
because there's a Zope 3 security wrapper in the way.
2. A similar problem occurs with the 'modules' element, some Zope 3
security wrapper prevents it from being usable
3. request.AUTHENTICATED_USER isn't set properly, it returns
Unauthenticated (or what is it) even though the client has logged in.
AccessControl.getSecurityManager.getUser() does return the correct user
object (so that's also a work-around for the problem, perhaps even
better than using the AUTHENTICATED_USER var).
4. (minor one and discussed by faassen on the channel) form vars aren't
passed to methods as arguments, so for a request to
'some_method?foo=bar' some_method is called without the 'foo' argument,
to get it's value one needs to use something like 'request['foo']'
That's what I ran into so far, I guess more will follow later... I don't
know if I'm able to fix any of the problems mentioned, I'll have a go at
it later but I thought it would be wise to report them so that they're
at least known...
Cheers,
Guido
More information about the z3-five
mailing list