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

Add option for interpreter flags for a Poetry script #8757

Closed
2 tasks done
takanuva15 opened this issue Dec 7, 2023 · 3 comments
Closed
2 tasks done

Add option for interpreter flags for a Poetry script #8757

takanuva15 opened this issue Dec 7, 2023 · 3 comments
Labels
kind/feature Feature requests/implementations

Comments

@takanuva15
Copy link

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

Feature Request

I would like to be able to specify interpreter flags when running a Poetry script. In my case, when running my scripts locally, I use the -O flag to toggle debug mode as I'm testing my scripts.

I have already reviewed #3335 where they talk about using an environment variable, but that isn't flexible for cases where an interpreter flag doesn't have an environment variable. Also, that solution doesn't work great on Windows where you can't prepend env variables so simply as unix bash allows.

If there's not a clean way to specify an interpreter flag directly to poetry run, I think the next best thing could be to add a "flags" value in the expanded scripts table where we can put the flags we want to execute for a given script.

@takanuva15 takanuva15 added kind/feature Feature requests/implementations status/triage This issue needs to be triaged labels Dec 7, 2023
@dimbleby
Copy link
Contributor

dimbleby commented Dec 7, 2023

there's no such thing as a "poetry script", they are just regular package entrypoints but defined in poetry syntax.

Therefore it is not desirable to be adding poetry-special bells and whistles. If you find entrypoints lacking then you should take that to the python packaging authority and write a PEP.

@Secrus
Copy link
Member

Secrus commented Dec 8, 2023

There is no standard for that and we are not going to make Poetry a special case. Once there are PEP-ified standards for that, we can get back to the topic.

@Secrus Secrus closed this as not planned Won't fix, can't repro, duplicate, stale Dec 8, 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
@abn abn removed the status/triage This issue needs to be triaged label Mar 2, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
kind/feature Feature requests/implementations
Projects
None yet
Development

No branches or pull requests

4 participants