You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(protocols): three TLS extension rejections are loud on PyPy, failing the required pypy3.11 leg #2637
The required Python pypy3.11 leg has failed on every Unit Tests run since #2595 merged (0ef7139a6). The runs include #2617, #2614 G2, #2483, #2561, the #2614 padding commit and #2616. Each fails the same three subtests of tests/protocols/application/test_tls_extension_quiet_rejection_2514_unit.py::QuietRejectionTests::test_a_shipped_decoders_rejection_is_quiet: alpn list length mismatch, supported_groups odd length and supported_versions odd length. The failure is:
AssertionError: <function set_trim_rule.<locals>.tbtrim_excepthook ...> is not <function QuietRejectionTests.setUp.<locals>._sys_sentinel ...>
The rejection should be quiet under #2588's rule. On PyPy it instead installs the traceback-trimming excepthook, so these three handled refusals are loud there. The other cases in the same test pass, and so does CPython. The fix is to find what differs on PyPy for these three decode paths (each raises through a list or vector length check) and fix it at the source.
Landed on main as 18544c3c9 (test-only). The failure was in the tests, not PyPy, and the decoders were never loud.
Cause:QuietRejectionTests.setUp installs its hook sentinels before pcapkit is re-imported. That re-import calls tbtrim.set_trim_rule, which replaces both hooks. The test therefore fails whenever it runs first in its class on a worker. PyPy's xdist sharding happened to place it there, and the same isolated run reproduces it on CPython.
Fix:
The two affected test classes import pcapkit before saving their sentinels. One is in this module; the other is a latent case in test_dtls_connection_id_2515_unit.
A new project guard fails on any test that sets an excepthook after a purge and before importing pcapkit.
Docstrings:BaseError and _install_excepthook say importing pcapkit never touches the hooks, but pcapkit/__init__.py does install tbtrim's hook at import, outside dev mode. That question is filed separately.
Activity
fix(tests): import pcapkit before the hook sentinels go in (#2637)
JarryShaw commentedon Nov 2, 2026
Landed on
mainas18544c3c9(test-only). The failure was in the tests, not PyPy, and the decoders were never loud.Cause:
QuietRejectionTests.setUpinstalls its hook sentinels beforepcapkitis re-imported. That re-import callstbtrim.set_trim_rule, which replaces both hooks. The test therefore fails whenever it runs first in its class on a worker. PyPy's xdist sharding happened to place it there, and the same isolated run reproduces it on CPython.Fix:
pcapkitbefore saving their sentinels. One is in this module; the other is a latent case intest_dtls_connection_id_2515_unit.pcapkit.Docstrings:
BaseErrorand_install_excepthooksay importing pcapkit never touches the hooks, butpcapkit/__init__.pydoes install tbtrim's hook at import, outside dev mode. That question is filed separately.docs(changelog): fold NoPayload's move, family-base dispatch and the …