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

Changes to make the library wok with Python3. Tested with Python 3.4.… #14

Closed

Conversation

AtlasPilotPuppy
Copy link

…3.NOTE: Changes are not backward compatible

@AtlasPilotPuppy
Copy link
Author

These changes are not backward compatible. These may need to go in a separate fork/ branch.

@DavidMuller
Copy link
Owner

Thanks for your work here @anantasty

These changes are not backward compatible. These may need to go in a separate fork/ branch.

Is there anything in particular stopping us from making backwards compatible changes? I don't have much experience with creating python2 + python3 compatible projects, but is, roughly, something like this possible: "if python3, from urllib.parse import urlparse, quote", "elif python2, from urllib import urlparse, quote"?

@AtlasPilotPuppy
Copy link
Author

We could a library such as six to make that possible. I just wanted to put
these out there. I can work on a more elegant fix some time

On Mon, Mar 21, 2016, 09:26 David Muller notifications@github.com wrote:

Thanks for your work here @anantasty https://github.com/anantasty

These changes are not backward compatible. These may need to go in a
separate fork/ branch.

Is there anything in particular stopping us from making backwards
compatible changes? I don't have much experience with creating python2 +
python3 compatible projects, but is, roughly, something like this possible: "if
python3, from urllib.parse import urlparse, quote", "elif python2, from
urllib import urlparse, quote"?


You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub
#14 (comment)

…arse module. THis works both in python 2 and 3.
@AtlasPilotPuppy
Copy link
Author

So i added six as a requirement which is an elegant way to handle this issue. We could also resort to a

try:
    import python2-lib
except ImportError:
    import python3-lib

instead of using six so we arent bloating the package.

@jlaine
Copy link
Contributor

jlaine commented Jun 17, 2016

I have submitted an alternative approach for supporting python2 + python3, which does not use six in #16

@DavidMuller
Copy link
Owner

python3 to should be added by #16

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

Successfully merging this pull request may close these issues.

3 participants