Conversation
|
@claude review |
|
Claude finished @andypost's task in 3m 58s —— View job Review:
|
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: fddba34c03
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
|
||
|
|
||
| @pytest.mark.skip('not yet, unsafe') | ||
| @pytest.mark.skipif(not option.unsafe, reason='not yet, unsafe') |
There was a problem hiding this comment.
Keep the unfinished listener test unconditionally skipped
When a developer runs pytest --unsafe test or targets test_configuration.py, this marker now enables test_listeners_empty, which still asserts behavior explicitly labeled “not yet”; the current listener validation accepts an empty object because none of nxt_conf_vldt_listener_members is required. The workflow avoids the failure only by passing --unsafe to the node-only test path, so the general unsafe suite is now guaranteed to fail. Leave this test unconditionally skipped until empty listeners are rejected.
Useful? React with 👍 / 👎.
fddba34 to
532b66e
Compare
|
The seven red legs are not defects in this PR. The Autobahn payload-size cases it enables have never run in CI, and they found two real module bugs, now filed:
Suggest xfailing Note this branch is also CONFLICTING against master and needs a rebase. |
…emented cases, and pass --unsafe everywhere
Two unconditional @pytest.mark.skip('not yet, unsafe') and three in-body
"if not is_unsafe: pytest.skip()" gates become one
@pytest.mark.skipif(not option.unsafe). option.unsafe is set in
pytest_configure, so it is available at collection time. The now-dead
is_unsafe fixture goes with them.
test_configuration.py's two remaining skipif marks are not "unsafe" at
all: they assert behaviour the controller does not implement (an empty
listener object is accepted; an application object with only "type" set
is accepted). Gating them on --unsafe made a plain "pytest --unsafe
test/" permanently red the day anyone passed the flag, and no leg ever
did -- so the three Autobahn 9.1.1-9.6.6 cases had never run either.
Both marks become non-strict @pytest.mark.xfail instead, naming the
unimplemented behaviour; an XPASS is then a signal instead of a failure
the day the controller starts rejecting these.
With that fixed, --unsafe can go on every leg. Also add 'unsafe': False
to Options' defaults: __getattr__ raises AttributeError for anything
absent, and unsafe is only injected by pytest_configure, so the
module-level marks made several test modules unimportable outside a
pytest run.
Turning the flag on proved the three Autobahn cases are not merely slow.
Node passes on every version; the asgi and java ones fail in about four
minutes against a thirty minute budget, for two module bugs that are now
filed: the ASGI module enforces a private 1 MiB frame cap and ignores
max_frame_size (#429), and the java module fragments any text message
above 8 KiB for the same reason (#430). Both cases keep their skipif and
gain a non-strict xfail naming the issue, so the coverage lands green
and fixing either bug turns its case into an XPASS. The gate had been
hiding these two defects, not minutes.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
test_configuration.py::test_unprivileged_user_error requires a unitd that is not root, which is the reverse of every sudo'd leg, so it had never run. The non-sudo step runs that file alongside the capget fallback tests. The file's other cases need no privilege: its only require() is the unprivileged one, and it talks solely to the control socket. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
532b66e to
4f59086
Compare
Two changes that turn on tests which have never run in CI.
The three Autobahn websocket cases are gated on
--unsafe, and no leg had ever passed that flag.Two unconditional
@pytest.mark.skip('not yet, unsafe')marks and three in-bodyif not is_unsafe: pytest.skip()gates collapse into one@pytest.mark.skipif(not option.unsafe),evaluated at collection because
option.unsafeis set inpytest_configure.test_configuration.pyalso carried two cases marked unsafe, but they are a different thing: theyassert that the controller rejects an empty listener object, which it does not, because no member of
nxt_conf_vldt_listener_membersis required. Those are known-broken, not slow, so they arenon-strict
xfailrather than flag-gated. That keeps--unsafemeaning "slow" and nothing else, soa plain
pytest --unsafe test/is no longer guaranteed to fail, and the day the controller startsrejecting them an XPASS says so instead of silence. Both already XPASS in one leg, which is exactly
the signal
skipnever gave.With that separation the flag needs no per-leg logic, so every leg passes it and picks up whichever
Autobahn case its own testpath contains.
What turning the flag on found
Node passes on all four versions. The other two do not, and the failures are real module bugs, not
flakes or timeouts. Every leg finished in about four minutes against a thirty minute budget, so the
'long run'reason had been hiding defects rather than minutes for years.UnicodeDecodeErrormax_frame_sizeAssertionError: finmax_frame_sizeThe asgi and java cases are therefore marked non-strict
xfailagainst those two issues, keepingtheir
skipifso they still only run under the flag. The coverage lands green, the bugs stayvisible and attributed, and fixing either issue turns its case into an XPASS. Dropping
--unsafeagain would put both defects back into silence, which is the one outcome worth avoiding.
The unprivileged step
test_configuration.py::test_unprivileged_user_errorrequires a unitd that is not root, the reverseof every sudo'd leg, so it had never run either. The non-sudo step now runs that file alongside the
capget fallback tests. The file's other cases need no privilege: its only
require()is theunprivileged one, and it talks solely to the control socket.
The dead
is_unsafefixture goes with the gates that used it, andoption.unsafegains a default sothe module-level marks do not make those files unimportable outside a pytest run.
Rebased onto master after #418, keeping its
set -o pipefailandteeand adding--unsafeto bothinvocations. No longer waits on anything.
🤖 Generated with Claude Code