python / python/cpython

test_python_executable failure on macOS 12.7.5

未關閉
#120,961 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

還沒有人認領這個 Issue。

OS-mac tests
主要語言
Python
星號
77.2k
分支
36k
PR 合併指標
PR 指標待擷取

描述

Test added in #120006 fails when running in my private buildbots.

Since it passed in CI, I suspect this means it was relying on the machine configuration or the presence of the source tree to get through the tests. The CI machine was running macOS-13.6.7-x86_64-i386-64bit-Mach-O and mine is macOS-12.7.5-x86_64-i386-64bit-Mach-O.

Mine also applies some install_name_tool modifications to the binaries and deploys them to a new machine before running tests, but given every other test passes and the failure here is to locate a Python module rather than a native one, I have to assume that's not impactful.

stderr:
---
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Fatal Python error: Failed to import encodings module
Python runtime state: core initialized
ModuleNotFoundError: No module named 'encodings'

Current thread 0x0000000115121600 (most recent call first):
  <no Python frame>
---

I'm not in a position to test or debug, unfortunately. I see that Ned proposed to deprecate this variable entirely in #91057, so I wonder how badly we need this test?

貢獻指南

開啟貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

研究方向

從 #120006 中新增的 test_python_executable 測試開始,並在報告中描述的 macOS 12.7.5 建置上重現它。將其行為與 macOS 13.6.7 CI 環境進行比較,包括報告中提到的 deployment 和 install_name_tool 差異。完成的標準是找出缺少 encodings 模組的原因,並確定是否需要變更測試或其假設。

由索引模型根據 Issue 內容生成。

評估

技術堆疊
macos, python
領域
operating-systems, testing-qa
Issue 類型
缺陷
難度
4/5
預估耗時
3-5 天
活躍度
停滯
描述清晰度
需要釐清
新手友好度
35/100

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。