Issue1537

classification
Title: expat: org.python.apache.xerces.parsers.SAXParser
Type: behaviour Severity: minor
Components: Library Versions: 2.5.1
process
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: kwatford
Priority: Keywords:

Created on 2010-01-11.20:37:25 by kwatford, last changed 2010-01-11.20:37:25 by kwatford.

Messages
msg5423 (view) Author: Ken Watford (kwatford) Date: 2010-01-11.20:37:24
I'm using jython2.5.1 in MATLAB's JVM. Upon trying to parse an XML file with ElementTree, XMLParser.__init__ tries to get XMLReaderFactory to find "org.python.apache.xerces.parsers.SAXParser". Probably due to limitations in MATLAB's stupid classloader, this does not work (throws a SAXException/ClassNotFoundException)

The only relevant comment on why this weird name is used is expat.py line 51: "Name mangled by jarjar?". 

Manually setting expat._xerces_parser to "org.apache.xerces.parsers.SAXParser" resolves the issue.

Perhaps a try block around the XMLReaderFactory call?
History
Date User Action Args
2010-01-11 20:37:25kwatfordcreate