Skip to content

Detect python version#1518

Closed
michielboekhoff wants to merge 3 commits into
python-poetry:developfrom
michielboekhoff:detect-python-version
Closed

Detect python version#1518
michielboekhoff wants to merge 3 commits into
python-poetry:developfrom
michielboekhoff:detect-python-version

Conversation

@michielboekhoff
Copy link
Copy Markdown

This PR allows users to manually specify the Python interpreter to use when installing Poetry. If one is not passed, it will try to find a python3 executable on the PATH, and otherwise default to the python executable. This is an implementation as discussed with @brycedrennan in #1042.

@michielboekhoff
Copy link
Copy Markdown
Author

Not sure what's going on with the Windows builds there.

The Linux 2.7 build appears to be failing as it was using the python3 executable. I'm fixing this in the CI now.

@Jamim
Copy link
Copy Markdown
Contributor

Jamim commented Oct 30, 2019

Similar PR: #1494.

@michielboekhoff
Copy link
Copy Markdown
Author

@Jamim - thanks for that!

This is as per the discussion in #1042, going a few steps further than what was done there and in #1494.

@nottrobin
Copy link
Copy Markdown

nottrobin commented Dec 16, 2019

Can't wait for this! When I saw https://github.com/python-poetry/poetry/releases/tag/1.0.0 had been released, I really thought it would have included this fix :(

Please let me know if there's any way I could help.

@nottrobin nottrobin mentioned this pull request Dec 16, 2019
3 tasks
@michielboekhoff
Copy link
Copy Markdown
Author

@nottrobin - cheers for the enthusiasm about this! I've just updated this project against the latest develop branch.

Apologies about the force-pushing; I did this to clean up some commits and to keep the history clean.

If anyone would like to take a look at this, it'd be much appreciated. I'd still love to see this included in Poetry.

@nottrobin
Copy link
Copy Markdown

nottrobin commented Dec 17, 2019

A note: When running poetry v1.0.0 I'm still getting a pip not found error (in Ubuntu 18.04 when I don't have python2 installed & haven't manually created a symlink). I thought this had been fixed in previous work, but it must have crept back in.

Should this PR use a similar mechanism for ensuring that the pip binary used is appropriate? Either {python} -m pip {command} or {pip} {command}?

Comment thread get-poetry.py
force=False,
accept_all=False,
base_url=BASE_URL,
binary=None,
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This probably should not be None

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Mar 1, 2024

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.

@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Mar 1, 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

Successfully merging this pull request may close these issues.

5 participants