-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Poetry incorrectly resolves netmiko dependencies #844
Comments
This is on if sys.version_info < (3,):
requirements.append("enum34")
requirements.append("ipaddress") at this line: https://github.com/ktbyers/netmiko/blob/develop/setup.py#L12 This is not the recommended way of doing it. They should use environment markers. Basically, when they package
where the |
Thanks for the analysis @sdispater @ktbyers would you consider adding environment marker? |
Yes, I am fine doing that. |
I keep running into this issue (which is the same issue as #881) in various third-party modules; I found it in 2 just today (confluent_kafka and requests-futures, FWIW). It seems that comparing sys.version_info is a very common pattern among package developers, and its a shame that poetry is mostly unusable until these other developers fix their setup scripts. Is there anyway Poetry could work around this? |
PEP-508 recommends Environment markers for better compatibility with modern build tools and dependency managers such as Poetry. https://www.python.org/dev/peps/pep-0508/#environment-markers E.g., See also: python-poetry/poetry#844 python-poetry/poetry#881
Alternatively, if there were a way to tell poetry to explicitly prevent the installation of some package, that would help, at least. |
This was fixed in Netmiko: We should close this issue. |
Poetry is great, thanks for building it! I ran into the enum34 issue as well. If I understand correctly, in my case it was due to my grpcio "=1.19.0" dependency (in As a workaround, I declared a dependency on There's some discussion of using environment markers, but I'm afraid I don't know enough to comment on this PR or provide other support to the Poetry / the grpc project: grpc/grpc#12976 |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Closing this issue automatically because it has not had any activity since it has been marked as stale. If you think it is still relevant and should be addressed, feel free to open a new one. |
I have exactly the same problem, I know that the Ideally, poetry would support temporarily fixing such broken packages by overriding their dependency declarations. Basically what was proposed in #1122 (comment) sounds absolutely epic. Here's a workaround for anyone interested:
|
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
-vvv
option).Issue
It seems that poetry incorrectly resolves netmiko dependencies. Here is the output with poetry in Docker (Python 3.6.7):
Here is the output from pip when installing
netmiko
(enum34
is not installed):The text was updated successfully, but these errors were encountered: