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

python3 support #177

Open
rathann opened this issue Feb 25, 2019 · 1 comment
Open

python3 support #177

rathann opened this issue Feb 25, 2019 · 1 comment

Comments

@rathann
Copy link

rathann commented Feb 25, 2019

Building and using the python extension with python3 fails. Apart from fixing detection in configure (macros/python.m4), it's also necessary to port (py_ext/ming.py) to python3 (2to3 works fairly well, but doesn't fix whitespace inconsistencies). However, that's still not enough. Apparently, the SWIG bindings use python2-only APIs like PyFile_Check and PyFile_AsFile, which are not available in python3. See https://docs.python.org/3/c-api/file.html and https://stackoverflow.com/questions/16130268/python-3-replacement-for-pyfile-asfile .

@cbehan
Copy link

cbehan commented Sep 12, 2020

I don't use the API but it would seem that a change I just made to the SWIG bindings has a chance of working. We can find out if it's worthwhile to submit if you want to give it a try.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants