Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

py2exe, PyXML, and utf-16-be Error

2 views
Skip to first unread message

David Brownell

unread,
Aug 23, 2004, 1:13:30 PM8/23/04
to
I am using the XMLValidateParser in the PyXML library
(xml.sax.sax2exts.XMLValParserFactory.make_parser). When I run my
script, everything works as expected.

When I "compile" my script using py2exe, I get the following error
when running the exe:

Traceback (most recent call last):
<my modules removed for brevity>
File "xml\sax\sax2exts.pyc", line 13, in make_parser
File "xml\sax\saxexts.pyc", line 64, in make_parser
File "xml\sax\saxexts.pyc", line 42, in _create_parser
File "xml\sax\drivers2\drv_xmlproc.pyc", line 9, in ?
File "xml\parsers\xmlproc\xmlproc.pyc", line 14, in ?
File "xml\parsers\xmlproc\dtdparser.pyc", line 12, in ?
File "xml\parsers\xmlproc\xmlutils.pyc", line 43, in ?
LookupError: unknown encoding: utf-16-be

While using py2exe, I specify "--packages xml". Is there something
else I need to specify to enable utf-16-be encoding?

Thanks in advance for your help!
David Brownell

Thomas Heller

unread,
Aug 23, 2004, 2:44:33 PM8/23/04
to
david_b...@hotmail.com (David Brownell) writes:

I would guess "--packages xml,encodings" should do the trick.

Thomas

David Brownell

unread,
Aug 24, 2004, 2:11:34 AM8/24/04
to
Thanks, Thomas, that did the trick.
0 new messages