That's not a parser issue, that's according to the DOM specification.
> Attr objects inherit the Node interface, but since they are not
> actually child nodes of the element they describe, the DOM does
> not consider them part of the document tree.
They are not child nodes, so they shouldn't be in the child_nodes collection.