absolute_url is empty in __getattribute__?
Hi In the line to test __getattribute__ to override some properties I try to access to the object's absolute_url but it's empty How can I have the absolute_url at object's __getattribute__? Thanks again -- Mis Cosas http://blogs.sistes.net/Garito
On 7/11/06, Garito <garito@sistes.net> wrote:
In the line to test __getattribute__ to override some properties I try to access to the object's absolute_url but it's empty
its not a property, ist a method: ObjectManagerItem.absolute_url() --knitti
knitti escribió:
On 7/11/06, Garito <garito@sistes.net> wrote:
In the line to test __getattribute__ to override some properties I try to access to the object's absolute_url but it's empty
its not a property, ist a method: ObjectManagerItem.absolute_url()
--knitti I know but if you call it returns ""?
-- Mis Cosas http://blogs.sistes.net/Garito
On 7/11/06, Garito <garito@sistes.net> wrote:
knitti escribió:
On 7/11/06, Garito <garito@sistes.net> wrote:
In the line to test __getattribute__ to override some properties I try to access to the object's absolute_url but it's empty
its not a property, ist a method: ObjectManagerItem.absolute_url()
--knitti I know but if you call it returns ""?
doesn't sound like an existing object. when I call some_zope_object.absolute_url(), I do get exactly the absolute url. you could try to be a bit more verbose on what you are actually doing, how do you access absolte_url()? paste some code, and tell why you think it is broken, it is much easier to talk about. --knitti
On 7/11/06, Garito <garito@sistes.net> wrote:
Hi In the line to test __getattribute__ to override some properties I try to access to the object's absolute_url but it's empty
__getattr__ is always called on the non-acquicision wrapped object. Hence, __getattr__ doesn't know anything about it's surroundings.
How can I have the absolute_url at object's __getattribute__?
You can't, unless you bend over backwards, and there are surely easier ways to do whatever you are trying to do. What are you trying to achieve? -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/
Lennart Regebro escribió:
On 7/11/06, Garito <garito@sistes.net> wrote:
Hi In the line to test __getattribute__ to override some properties I try to access to the object's absolute_url but it's empty
__getattr__ is always called on the non-acquicision wrapped object. Hence, __getattr__ doesn't know anything about it's surroundings.
How can I have the absolute_url at object's __getattribute__?
You can't, unless you bend over backwards, and there are surely easier ways to do whatever you are trying to do.
What are you trying to achieve?
Hi Lennart! Did you read the thread "Override members value"? I'm trying to do something like a TALES property or similar -- Mis Cosas http://blogs.sistes.net/Garito
Garito escribió:
Hi In the line to test __getattribute__ to override some properties I try to access to the object's absolute_url but it's empty
How can I have the absolute_url at object's __getattribute__?
Thanks again
Hi all! I rethink my problem and I solve all my questions with the new approach Thank you so much!!!! -- Mis Cosas http://blogs.sistes.net/Garito
participants (3)
-
Garito -
knitti -
Lennart Regebro