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

Poetry install with path dependencies and entry points is unable to load the package #3930

Closed
2 tasks done
kalyangvs opened this issue Apr 12, 2021 · 3 comments
Closed
2 tasks done

Comments

@kalyangvs
Copy link

  • I have searched the issues of this repo and believe that this is not a duplicate.
  • I have searched the documentation and believe that my question is not covered.

Issue

If there are path dependencies and an entry point present as poetry plugin, the entry point is unable to be loaded.

poetry new aa
poetry new bb
poetry new cc
cd cc
sed -i  '/\python*/a  aa = {path = "../aa"} \nbb = {path = "../bb"}' pyproject.toml
echo '
[tool.poetry.plugins."service"]
"cc" = "cc.service:CCService"' >> pyproject.toml
poetry install

In python:

import pkg_resources
for entry_point in  pkg_resources.iter_entry_points("service"):
    service = entry_point.load()

results in pkg_resources.extern.packaging.requirements.InvalidRequirement: Invalid URL: ../aa

Please look into the issue.

@kalyangvs
Copy link
Author

The current workaround is to re-install the packages using pip by removing path dependencies from toml file, is there a clean solution to this?
@finswimmer @abn

@finswimmer
Copy link
Member

Hello @kalyangvs,

you haven't come back to this issue for a long while. So I assume this is solved in the meantime and I can close this ticket.

Feel free to leave a comment if you disagree.

fin swimmer

@finswimmer finswimmer closed this as not planned Won't fix, can't repro, duplicate, stale May 11, 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
None yet
Projects
None yet
Development

No branches or pull requests

2 participants