python-poetry / python-poetry/install.python-poetry.org
Poetry environment breaks when Homebrew upgrades Python on MacOS
Personne n'a encore pris cette issue.
- Langage dominant
- Python
- Étoiles
- 255
- Forks
- 65
- Merge moyen
- 2 h 48 min
- PR mergées (30 j)
- 1
Description
Issue experienced in Poetry 1.2.1
Python version 3.10.6_2 -> 3.10.7 and 3.10.7 -> 3.10.8 upgrades
OS version MacOS 12.6
(not project-specific so no pyproject.toml)
Issue
Poetry commands cease working and throw errors after upgrading the installed Python version using Homebrew. This has occurred the last two times (3.10.6_2 upgrade to 3.10.7 and 3.10.7 upgrade to 3.10.8) using brew upgrade which included the two Python updates. Afterward, attempting to use any Poetry command fails with error output similar to the following:
poetry --version
dyld[42062]: Library not loaded: '/usr/local/Cellar/python@3.10/3.10.7/Frameworks/Python.framework/Versions/3.10/Python'
Referenced from: '/Users/keith/Library/Application Support/pypoetry/venv/bin/python'
Reason: tried: '/usr/local/Cellar/python@3.10/3.10.7/Frameworks/Python.framework/Versions/3.10/Python' (no such file), '/Library/Frameworks/Python.framework/Versions/3.10/Python' (no such file), '/System/Library/Frameworks/Python.framework/Versions/3.10/Python' (no such file)
zsh: abort poetry --version
In both cases, the only Python installations available are system packages (if these even still exist) or those installed by Homebrew. Poetry has only been installed via the recommended curl -sSL https://install.python-poetry.org | python3 - command. The only way I've found to restore Poetry functionality after brew upgrade is to uninstall via the same recommended script i.e. curl -sSL https://install.python-poetry.org | python3 - --uninstall and then to reinstall Poetry
Guide de contribution
Aucun guide de contribution indexé pour ce dépôt
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Piste de recherche
Commencez par reproduire l’échec avec le script d’installation recommandé et une mise à niveau de Python via Homebrew, puis examinez comment l’environnement Poetry installé fait référence au framework Python. Vérifiez le résultat avec poetry --version après une mise à niveau et confirmez que Poetry reste utilisable sans le désinstaller ni le réinstaller.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- python
- Domaine
- tooling
- Type d'issue
- Bug
- Difficulté
- 4/5
- Temps estimé
- 3-5 jours
- Activité
- À l'abandon
- Clarté
- Plutôt claire
- Accessibilité débutants
- 35/100