_osx_support._default_sysroot is dead in CPython but used downstream with no public replacement
まだ誰も着手していません。
- 主要言語
- Python
- スター
- 77.2k
- フォーク
- 35.9k
- PR マージ指標
- PR 指標を取得中
説明
_osx_support._default_sysroot(cc) has no caller inside CPython, yet several downstream projects import it directly and there is no public replacement to send them to.
Lifecycle
- GH-23301 (bpo-41116) added it to locate the macOS 11 SDK sysroot when building extensions.
- Its only in-tree caller lived in
distutils. GH-99061 (gh-92584) removeddistutils, so nothing in CPython calls it now.
Downstream use
A GitHub code search finds live callers: pyston (setup.py), PyOxidizer (vendored distutils/unixccompiler.py), and the macports and fink Python patches. They call it to discover the SDK sysroot when compiling extensions.
No public replacement
sysconfig does not expose the SDK sysroot and distutils is gone, so a downstream user has nowhere supported to move. They would shell out to xcrun --show-sdk-path or copy the function body.
Question
For this private helper with live downstream use and no public equivalent, which way do we go:
- Keep it as-is and document that it is unsupported.
- Add a supported public equivalent first, then deprecate and remove.
- Remove it now under the "private API carries no guarantee" rule and accept the breakage.
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
まず _osx_support._default_sysroot(cc) と、issue で挙げられている下流のエントリーポイント(pyston の setup.py、PyOxidizer に vendored された distutils/unixccompiler.py、macports および fink のパッチ)を調査します。サポート対象の置き換え、ドキュメント化、削除のいずれの方針が適切かを判断します。選択したポリシーと下流の移行経路が明確になれば、作業は完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- python
- 領域
- build-system
- issue の種類
- 機能追加
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 活発さ
- 静か
- 明瞭さ
- 説明が足りない
- 初心者へのやさしさ
- 30/100