mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-07-04 08:02:34 +03:00
Fix python bindings with versions older than 2.7
Need fixing on the Capsule usage, the lack of PyBytes, lack of io module and the way to access exception details.
This commit is contained in:
@ -77,7 +77,9 @@ class ioWrapper:
|
||||
ret = self.__io.read()
|
||||
else:
|
||||
ret = self.__io.read(len)
|
||||
except Exception as e:
|
||||
except Exception:
|
||||
import sys
|
||||
e = sys.exc_info()[1]
|
||||
print("failed to read from Python:", type(e))
|
||||
print("on IO:", self.__io)
|
||||
self.__io == None
|
||||
|
Reference in New Issue
Block a user