`test_capi`: `test_threadstate_set_stack_protection` is flaky on Azure CI
未關閉
還沒有人認領這個 Issue。
tests
topic-C-API
type-bug
- 主要語言
- Python
- 星號
- 77.2k
- 分支
- 36k
- PR 合併指標
- PR 指標待擷取
描述
Bug report
Bug description:
test.test_capi.test_misc.Test_testinternalcapi.test_threadstate_set_stack_protection fails on Azure Pipeline.
For example in this run https://dev.azure.com/Python/cpython/_build/results?buildId=173303:
test_threadstate_set_stack_protection (test.test_capi.test_misc.Test_testinternalcapi.test_threadstate_set_stack_protection) ... Assertion failed: ts->c_stack_soft_limit < ts->c_stack_top, file D:\a\1\s\Modules\_testinternalcapi.c, line 3045
Fatal Python error: Aborted
Current thread 0x000011f0 (most recent call first):
File "D:\a\1\s\Lib\unittest\case.py", line 637 in _callTestMethod
File "D:\a\1\s\Lib\unittest\suite.py", line 122 in run
File "D:\a\1\s\Lib\unittest\suite.py", line 84 in __call__
File "D:\a\1\s\Lib\unittest\runner.py", line 256 in run
File "D:\a\1\s\Lib\test\libregrtest\single.py", line 84 in _run_suite
File "D:\a\1\s\Lib\test\libregrtest\single.py", line 42 in run_unittest
File "D:\a\1\s\Lib\test\libregrtest\single.py", line 162 in test_func
File "D:\a\1\s\Lib\test\libregrtest\single.py", line 118 in regrtest_runner
File "D:\a\1\s\Lib\test\libregrtest\single.py", line 165 in _load_run_test
File "D:\a\1\s\Lib\test\libregrtest\single.py", line 210 in _runtest_env_changed_exc
File "D:\a\1\s\Lib\test\libregrtest\single.py", line 319 in _runtest
File "D:\a\1\s\Lib\test\libregrtest\single.py", line 348 in run_single_test
File "D:\a\1\s\Lib\test\libregrtest\worker.py", line 99 in worker_process
File "D:\a\1\s\Lib\test\libregrtest\worker.py", line 137 in main
File "D:\a\1\s\Lib\test\libregrtest\worker.py", line 141 in <module>
File "<frozen runpy>", line 87 in _run_code
File "<frozen runpy>", line 201 in _run_module_as_main
Current thread's C stack trace (most recent call first):
<cannot get C stack on this system>
Extension modules: _testcapi, _testlimitedcapi, _testinternalcapi, _testmultiphase, _testsinglephase, _testbuffer (total: 6)
CPython versions tested on:
CPython main branch
Operating systems tested on:
Windows
貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
研究方向
從 test.test_capi.test_misc.Test_testinternalcapi.test_threadstate_set_stack_protection 開始,檢查 Modules/_testinternalcapi.c 第 3045 行附近的位置,Azure Windows assertion 在此處失敗。在 Azure 環境中重現指定的測試,並追蹤涉及的 stack-limit 值。測試能在 Azure 上可靠通過且不再出現 assertion failure,即表示完成。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- azure, c, python
- 領域
- ci-cd, operating-systems, testing-qa
- Issue 類型
- 缺陷
- 難度
- 4/5
- 預估耗時
- 3-5 天
- 活躍度
- 冷清
- 描述清晰度
- 基本清楚
- 新手友好度
- 48/100