<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html><head><style>p {margin:0px;padding:0px;} blockquote { border: 0px; margin-top: 0px; margin-bottom: 0px; }</style></head><body style="">
<p><font color="#000000" face="Verdana" size="2">Hi,</font><br> </p><p><font color="#000000" face="Verdana" size="2"><blockquote type="cite"><br>> Is it a reasonable expectation that they act the same? (I think they <br>> haven't tested the code much with lxml 2, so basically they haven't <br>> exercised the first case... though looking at the code some I'm not sure <br>> it works with the second case either)<br><br>[...]<br><br>Currently, lxml.objectify is positioned as an API *on-top* of etree, although<br>things that behave differently are duplicated already. I haven't made up my<br>mind yet. However, I do feel that there may be more things that might want to<br>behave different in the future, so having them duplicated from the beginning<br>makes it a) easier to grow the different APIs in their respective direction,<br>and b) easier for users to use them consistently inside the module/package API<br>that they are using, without caring about the interaction with etree if they<br>don't use it.</blockquote></font></p><p> </p><p>Mirroring the etree API completely in objectify might make the incautious user</p><p>think that these modules can be used completely interchangeable, while they</p><p>are not.</p><p>And the difference are subtle, e.g. the indexing behaviour (sibling access in objectify,</p><p>children access in etree), and will not necessarily produce easily detectable errors.</p><p> </p><p>So for an lxml.objectify that exposes a full etree-API, it should be stated very prominently</p><p>that you can't just take your existing etree worker code and start using objectify</p><p>instead.</p><p> </p><p>Holger </p><p><font color="#000000" face="Verdana" size="2"><br></font></p><p> </p><div class="signature"><br /><br /><br />-- <br />Ist Ihr Browser Vista-kompatibel? Jetzt die neuesten <br />Browser-Versionen downloaden: http://www.gmx.net/de/go/browser</div></body></html>