actions / actions/setup-python
Add "Externally Managed Environments" support to block global package installations via pip
まだ誰も着手していません。
- 主要言語
- TypeScript
- スター
- 2.2k
- フォーク
- 739
- 平均マージ
- 6日 18時間
- マージ済み PR(30日)
- 1
説明
Description:
To prevent system package breakage, many Linux distributions are now restricting pip install to virtual environments or uv environments (something private either way). In self-hosted environments, especially when using ephemeral runners, the hosted tools cache functionality is critical for scaling.
The current methodology allows a pip install to install directly to the cached directory for a given Python after installation, which leads to potentially broken dependency trees and all other kinds of errors if developers are not careful with their package installs. It can also lead to weird race conditions in the same way.
I propose a new input for actions/setup-python that creates the EXTERNALLY-MANAGED file right before a version of Python is marked as available (e.g. creation of the x64.complete file) that would block global pip installs.
Justification:
Did all of this in the above. Didn't read the template first.
Are you willing to submit a PR?
Absolutely. This is more of a RFC to gauge the level of interest here.
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
まず、インストール済みの Python バージョンを利用可能として示す setup-python tool-cache パスを読み、その後、リンクされた外部管理環境の仕様を確認します。利用可能性が記録される前に marker をどのように作成すべきか、また、キャッシュされた Python インストールを対象とする既存のテストがどれかを判断します。完了条件は、キャッシュされたインタープリターに対するグローバルな pip インストールをブロックしつつ、サポートされている virtual-environment または uv ワークフローを妨げないことです。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- python, typescript
- 領域
- ci-cd, devops, tooling
- issue の種類
- 機能追加
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 35/100