Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better error messages #10

Closed
philippb opened this issue Sep 25, 2015 · 1 comment
Closed

Better error messages #10

philippb opened this issue Sep 25, 2015 · 1 comment
Assignees

Comments

@philippb
Copy link
Contributor

when some XML is wrongly formatted we get this error

Traceback (most recent call last):
  File "/Users/philipp/coding/ks-email-parser/venv/bin/ks-email-parser", line 9, in <module>
    load_entry_point('ks-email-parser==0.2.2', 'console_scripts', 'ks-email-parser')()
  File "/Users/philipp/coding/ks-email-parser/venv/lib/python3.4/site-packages/ks_email_parser-0.2.2-py3.4.egg/email_parser/__init__.py", line 64, in main
  File "/Users/philipp/coding/ks-email-parser/venv/lib/python3.4/site-packages/ks_email_parser-0.2.2-py3.4.egg/email_parser/__init__.py", line 26, in parse_emails
  File "/Users/philipp/coding/ks-email-parser/venv/lib/python3.4/site-packages/ks_email_parser-0.2.2-py3.4.egg/email_parser/renderer.py", line 157, in render
  File "/Users/philipp/coding/ks-email-parser/venv/lib/python3.4/site-packages/ks_email_parser-0.2.2-py3.4.egg/email_parser/renderer.py", line 115, in render
  File "/Users/philipp/coding/ks-email-parser/venv/lib/python3.4/site-packages/ks_email_parser-0.2.2-py3.4.egg/email_parser/renderer.py", line 115, in <dictcomp>
  File "/Users/philipp/coding/ks-email-parser/venv/lib/python3.4/site-packages/ks_email_parser-0.2.2-py3.4.egg/email_parser/renderer.py", line 97, in _render_placeholder
  File "/Users/philipp/coding/ks-email-parser/venv/lib/python3.4/site-packages/ks_email_parser-0.2.2-py3.4.egg/email_parser/renderer.py", line 74, in _inline_css
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/xml/etree/ElementTree.py", line 1325, in XML
    parser.feed(text)
xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 18, column 13

Something that indicates what XML file and maybe line would be good.

@ca77y
Copy link
Contributor

ca77y commented Feb 19, 2016

fixed in #15

@ca77y ca77y closed this as completed Feb 19, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants