Making enum34 dependency conditional on Python version.#3402
Making enum34 dependency conditional on Python version.#3402dhermes merged 1 commit intogoogleapis:masterfrom
Conversation
tseaver
left a comment
There was a problem hiding this comment.
I don't mind the change, but I'd really like to know how our code appears to work on Python 3.6 without this change.
|
So it seems package metadata (and therefore wheels) do not store the platform qualifiers, so installing from wheel in python 3 will cause enum34 to be installed. I had a fear that this would be the case: |
|
@jonparrott Shucks / thanks for bringing your packaging magic to bear here. What can we do? |
|
We can do it via extras_require={
':python_version<"3.4"': ['enum34'],
}This explodes with |
|
PR updated. Thanks a lot @jonparrott! I did the same |
|
Confirmed wheel installation skips enum34 on Python 3.6: And that enum34 is installed on Python 2.7 |
Fixes #3398.
After using this and running the unit tests, the dependency is indeed only present in Python 2.7: