On 11/ 5/10 07:42 AM, Dermot McCluskey wrote:
Hi,
Can I get a review for this fairly simple fix for ManifestParser bug:
http://monaco.sfbay/detail.jsf?cr=6997263
Webrev is at: http://cr.opensolaris.org/~dermot/webrev-6997263/
Thanks,
- Dermot
_______________________________________________
caiman-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/caiman-discuss
Hey Dermot,
One nit:
--------
This comment read oddly to me:
328 # If a sub-document was xincluded from a different directory
329 # from the main doc, lxml will add an attribute, eg
Perhaps/Suggestion:
If a sub-document was xincluded from a directory other than the main doc
lxml will ad an attribute, e.g.
One question:
-------------
I'm not a Python "re" expert but I think what you have may not work.
I've played around just now with it and it seems the "{...}" should be
"(...)":
py 1> re.match( r'^{.*}base$', 'http://bla hi betty base')
(note: None returned so no object is displayed here)
py 1> re.match( r'^(.*)base$', 'http://bla hi betty base')
<_sre.SRE_Match object at 0x81067a0>
(Note: This matched producing the Match object)
Also wouldn't it be better to try to be more prices, perhaps attempting
to match more in the string, perhaps adding: "^http:" and "base=" ?
e.g.:
re.match( r'^http:(.*)base=', 'http://bla hi betty base=hi')
Is the "=...$" stripped off when walking the tree, placing "base" at the
end? If so then checking for "base=" will, of course, not work.
Hope this helps.
Joe
_______________________________________________
caiman-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/caiman-discuss