-
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
Fix script entrypoints with extras #3431
Conversation
This will need to move to https://github.com/python-poetry/poetry-core as the relevant logic is now there. |
So, no fixes for v1.1? Or does this no longer fix the problem, because it worked well on an earlier 1.1.x version? |
@akeeman apologies. I groked the issue incorrectly. Reopening. |
That explains a lot! Thanks. |
Hi, can this pr be handled some time? It should be an easy fix for a simple but annoying problem. Yet it's open for several months now... |
@neersighted any thoughts? The problem still exists in 1.1.13 |
Looks like this is fixed in the current preview release (1.2.0b2). Can you confirm it? |
1.2.0b2 indeed does not have the issue. Is there any news on when it'll come out of beta? What's new for me is that |
Is it worth rebasing this PR to not install entrypoints when the required extra is not installed? I understand we're not doing anything /wrong/ currently because that's the pip behavior, but I'm open to being convinced that not installing entrypoints is beneficial to the user. |
I guess it would be better to do that in a separate pr pr, so let's not do the convincing here. |
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Consider this
pyproject.toml
file, which contains a script that has an extra (as implemented, but not yet documented -> #1181)Installing the above with
poetry install
givens you a script file including theThe last line is obviously incorrect. It should have been
foo()
In my opinion the file shouldn't have been installed at all in the first place, as those extras often go along with installing some optional packages to let them work. So I chose to skip the installation of the entrypoint as a whole if not all given extras are demanded. Note that I say "in my opinion", as this is different from setuptools. Setuptools will always install all script entrypoints.