Eryk Sun <[email protected]> added the comment:
Steve, the PR that you pushed has the wrong error and error message. I told
Philippe in msg377335 that ctypes raises FileNotFoundError with no error code.
For example:
>>> try: ctypes.CDLL('spam')
... except OSError as e: err = e
...
>>> err
FileNotFoundError("Could not find module 'spam' (or one of its
dependencies). Try using the full path with constructor syntax.")
>>> err.winerror is None
True
The advice to use dumpbin is fine and works well in simple cases. I wouldn't
use it generally since recursiveley parsing through the dependency graph of
every dependent DLL could be tedious.
----------
_______________________________________
Python tracker <[email protected]>
<https://bugs.python.org/issue25655>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com