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

Dependencies with and without extras are disjoint #7194

Closed
4 tasks done
Kuba314 opened this issue Dec 14, 2022 · 3 comments
Closed
4 tasks done

Dependencies with and without extras are disjoint #7194

Kuba314 opened this issue Dec 14, 2022 · 3 comments
Labels
kind/bug Something isn't working as expected status/triage This issue needs to be triaged

Comments

@Kuba314
Copy link

Kuba314 commented Dec 14, 2022

  • I am on the latest stable Poetry version, installed using a recommended method.
  • I have searched the issues of this repo and believe that this is not a duplicate.
  • I have consulted the FAQ and blog for any relevant entries or release notes.
  • If an exception occurs when executing a command, I executed it again in debug mode (-vvv option) and have included the output below.

Issue

Suppose I create a project (extra) with an extra dependency (or multiple). I then create another project (dep1) which depends on the project with extras and specify some extras. I then create a third project (dep2) which depends on extra but with no extras and dep1.

poetry gets stuck in an infinite loop trying to resolve this (also leaks a lot of memory while doing so). I guess the issue is that poetry considers extra and extra[net] packages disjoint. I'd assume these dependencies are compatible. I'd also assume that if they weren't compatible, poetry would raise an error which it does not.

@Kuba314 Kuba314 added kind/bug Something isn't working as expected status/triage This issue needs to be triaged labels Dec 14, 2022
@Kuba314
Copy link
Author

Kuba314 commented Dec 14, 2022

Caused by not specifying branch = "main" in dep1's extra dependency specification. Might be related to #7024

Kuba314 added a commit to Kuba314/lrc-file that referenced this issue Dec 14, 2022
Since poetry 1.2.0, if a package has extras and another package depends
on this one twice through other dependencies, but with different extra
requirements, poetry gets stuck and leaks memory. This is a workaround
for that.

See python-poetry/poetry#7194
Kuba314 added a commit to Kuba314/lrc-file that referenced this issue Jan 9, 2023
Since poetry 1.2.0, if a package has extras and another package depends
on this one twice through other dependencies, but with different extra
requirements, poetry gets stuck and leaks memory. This is a workaround
for that.

See python-poetry/poetry#7194
@Kuba314
Copy link
Author

Kuba314 commented Mar 24, 2023

Unable to reproduce anymore, closing.

@Kuba314 Kuba314 closed this as completed Mar 24, 2023
Copy link

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.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 29, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
kind/bug Something isn't working as expected status/triage This issue needs to be triaged
Projects
None yet
Development

No branches or pull requests

1 participant