Discussion:
Issue 213 in html5lib: element.sourceline is None
h***@public.gmane.org
2012-09-13 09:39:09 UTC
Permalink
Status: New
Owner: ----

New issue 213 by mtjahan...-***@public.gmane.org: element.sourceline is None
http://code.google.com/p/html5lib/issues/detail?id=213

When using lxml tree builder, source line of elements is not populated.

div_html = "<div>"

parser = html5lib.HTMLParser(tree=html5lib.getTreeBuilder("lxml"))
root = html5lib.parse(div_html)
div = list(root.iter())[-1] # <div> element
print(div.sourceline) # -> None

div = lxml.html.from_string(div_html)
print(div.sourceline) # -> 1
--
You received this message because you are subscribed to the Google Groups "html5lib-discuss" group.
To post to this group, send an email to html5lib-discuss-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
To unsubscribe from this group, send email to html5lib-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
For more options, visit this group at http://groups.google.com/group/html5lib-discuss?hl=en-GB.
h***@public.gmane.org
2012-09-19 15:02:06 UTC
Permalink
Comment #1 on issue 213 by geoffers: element.sourceline is None
http://code.google.com/p/html5lib/issues/detail?id=213

Off-hand, I believe there is no API to set sourceline, so we cannot (even
if we had the data) expose it in such a way.
--
You received this message because you are subscribed to the Google Groups "html5lib-discuss" group.
To post to this group, send an email to html5lib-discuss-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
To unsubscribe from this group, send email to html5lib-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
For more options, visit this group at http://groups.google.com/group/html5lib-discuss?hl=en-GB.
h***@public.gmane.org
2013-04-09 20:49:09 UTC
Permalink
Updates:
Status: WontFix

Comment #2 on issue 213 by geoffers: element.sourceline is None
http://code.google.com/p/html5lib/issues/detail?id=213

WontFix, per the above.
--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings
--
You received this message because you are subscribed to the Google Groups "html5lib-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to html5lib-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
To post to this group, send an email to html5lib-discuss-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
Visit this group at http://groups.google.com/group/html5lib-discuss?hl=en-GB.
For more options, visit https://groups.google.com/groups/opt_out.
Loading...