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

Circular dependency between poetry and poetry-plugin-export #240

Open
joshgc opened this issue Oct 13, 2023 · 2 comments
Open

Circular dependency between poetry and poetry-plugin-export #240

joshgc opened this issue Oct 13, 2023 · 2 comments

Comments

@joshgc
Copy link

joshgc commented Oct 13, 2023

Note:

  1. poetry depends on poetry-plugin-export https://github.com/python-poetry/poetry/blob/master/pyproject.toml#L36
  2. poetry-plugin-export depends on poetry https://github.com/python-poetry/poetry-plugin-export/blob/main/pyproject.toml#L21

This prevents bazel, which is circular-dependency-phobic, from building targets which depend on poetry. I believe the motivation for the dependencies are that

  1. Its nice if everyone who installs poetry just gets this export functionality. plugin-export makes poetry better
  2. Who would install plugin-export and not poetry? This dependency makes pip install do something reasonable.

I see three possible remediations:
A) Inline poetry-plugin-export since its not too much python and is always installed now anyway
B) Break the plugin-export dependency on poetry. This may add friction but the error messages should be obvious about whats going on.
C) Break the poetry dependency on plugin-export. This would probably require some code change so that poetry would discover if the extra package was present.

I think B is the easiest, but I'm really not sure. Would love to hear your thoughts.

@radoering
Copy link
Member

See python-poetry/poetry#5980 and python-poetry/poetry#6441 for some discussion.

@dimbleby
Copy link
Contributor

of those three B is the one that is definitely wrong! the plugin definitely does depend on poetry.

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

3 participants