no __len__ attribute in NodeList or the list base?

sndive at gmail.com sndive at gmail.com
Thu Nov 15 21:27:29 EST 2007


On Nov 15, 3:09 am, Hrvoje Niksic <hnik... at xemacs.org> wrote:
> snd... at gmail.com writes:
> > i extract class object from an instance of NodeList (minicompat.py)
> > like so
> > PyObject *pclass = PyObject_GetAttrString( nodelistinsance,
> > "__class__");
> > but
> >  PyObject_GetAttrString(pclass, "__len__")
> > returns NULL.
>
> Are you sure about that?

my apologies for the false alarm.
i was calling __len__ on Element rather than NodeList
thank you



More information about the Python-list mailing list