Submitted by : simon at: 2003-10-26T21:31:32+00:00 (14 years ago)
Name :
Category : Severity : Status :
Optional subject :  
Optional comment :

in Parents.py->get_ancestors the container is tested whether a given object can be accessed trough it by using hasattr(container,i). The object then is retrieved using container[i]. If it was retrieved by acqusition this will fail! Correction follows:

if not hasattr(container, i):
    continue        # Absent - ignore it.
ancestors[i] = None
obj = getattr(container, i) # was container[i] ROBERT

I do not know whether this could create loops! Maybe the code would better be rewritten like this:

try: obj = container[i] except: continue # Absent - ignore it. ancestors[i] = None

However the first way allows to have wikipages in a subfolder (as I use do have in my WikiTraker?) robert@redcor.ch


simon, 2002/03/19 06:32 GMT (via web):
Not sure what effect this has, but I'll trust your judgement. Included in 0.9.9. PS - thanks