Repository navigation
test(architecture): make the bare POSIX flag guard report violations and record the coordination ceiling - #8812
Closed
CharleoYang wants to merge 1 commit into
Closed
CharleoYang wants to merge 1 commit into
CharleoYang wants to merge 1 commit into
Conversation
…coordination ceiling Signed-off-by: Qi Yang <yangqi45@meituan.com>
CharleoYang
requested review from
huangruiteng,
loopx-agent and
songoow
as code owners
November 15, 2026 06:24
Author
|
Closing without merge: the owner directed that this work be published on the internal Sankuai remote (origin = ssh://git@git.sankuai.com/~yangqi45/loopx.git) and not on GitHub. The branch is pushed there; no GitHub PR is required. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
tests/architecture/test_posix_flag_portability.py::test_no_module_exceeds_its_bare_posix_flag_ceilingfails at the official baseline withValueError: too many values to unpack (expected 2)instead of reporting the offending module, and the guard's real violation is a module that deliberately refuses hosts without descriptor-relative opens.Root cause
for line, what in useswhereusesis the{ceiling, observed}mapping, so the diagnostic raises over its own keys.loopx/chat/coordination.py:85refuses the host unlessos.opensupports dir_fd and the three flags exist, then opens withO_DIRECTORY/O_NOFOLLOW/O_NONBLOCKat 92-98; the ceiling fixture had no entry for it.Change
path:line: expression, keeping both guard assertions and the guidance text.loopx/chat/coordination.py: 6inposix_flag_ceilings.jsonwith the line-85 capability refusal as the reason, per that fixture's own rule that a raise needs a recorded reason.Evidence
env -u PYTHONPATH LOOPX_USAGE_PING=0 TMPDIR=<outside repo> uv run --extra test python -m pytest -q tests/architecture/test_posix_flag_portability.py-> 5 passed, 0 failed, 0 skipped (11.35s).Not covered
The unsupported-host runtime branch was not exercised; the ceiling justification rests on the retained capability refusal at
loopx/chat/coordination.py:85. No product behaviour changed.