Repository navigation
test(app-logic): cover the production rebuild_redactors_for_open_sessions loop - #997
Merged
smart-ssh-coordinator[bot] merged 2 commits intoOct 27, 2026
Conversation
…n a real AppState (#989) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
6 tasks
6 tasks
There was a problem hiding this comment.
Review
Verdict: changes requested
Review level: normal
Blocking
crates/app-logic/src/ext.rs:26— the PR removesrebuild_redactors_for_sessionsfrom the publicextre-exports. The issue asks only to remove the test-only duplicaterebuild_for_open_sessions_withand says "the redaction logic is not modified". The function is part of the documented extension surface (docs/specs/0038-repository-app-shell-ci.md:264lists it under "Sitzungs-Erweiterung"), and an extension crate that importsapp_logic::ext::rebuild_redactors_for_sessionswould stop compiling. The re-export was most likely dropped only to silence an unused-import warning. Restore it (the in-crate tests usecrate::session_extension::…directly, so nothing else changes). If removal is intended, it needs a Spec 0038 update and a maintainer decision, which this test-only issue does not provide.
Non-blocking
- The PR body says "Spec: none (test-only)", but the removal above is a visible API change; see Blocking.
Verified
- counter-proof: replaced the loop body with a no-op →
test_ext_rebuild_redactors_for_open_sessions_touches_open_servers_onlyred (session/tests.rs:858), restored → green (executed:cargo +stable test -q --locked -p app-logic --lib ext_rebuild_redactors) - edge cases: zero sessions → no-op asserted; two sessions on one server →
[a,a,b](one call per session, once per server loop); closed server not seen → ok (read: session/tests.rs) - callers checked:
rebuild_redactors_for_sessionsre-export (spec 0038 lists it) → finding - tests run locally: the test above → 1 passed (executed)
- CI: all checks green (
gh pr checks 997) - UI / data: not touched
Timing analysis
- 1 test file analysed (read: session/tests.rs): no timing dependency; one in-process SQLite DB in a tempdir, no sleeps or real network.
Spec
- visible behaviour changed: none besides the public re-export removal
- spec searched (
rg -n rebuild_redactors docs/specs), spec covering it: 0038 line 264 - verdict: spec 0038 contradicts the code after this PR (blocking until the re-export is restored)
Security checks
- Redaction logic untouched; the test asserts that the secret is masked only after the rebuild. Threat model note present.
Follow-ups
- None.
…#989) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Contributor
Author
|
Review point (restore public re-export |
There was a problem hiding this comment.
Review
Verdict: approved
Review level: normal
Blocking
None.
Non-blocking
None.
Verified
- previous finding (re-export
rebuild_redactors_for_sessions) restored in 9893d58; delta is only that line (read: git diff e8cb8b5 HEAD) - counter-proof from the previous round unchanged, test untouched by the delta (executed earlier: no-op loop → red, restored → green)
- tests run locally:
cargo +stable test -q --locked -p app-logic --lib ext_rebuild_redactors→ 1 passed (executed) - CI: all checks green (
gh pr checks 997) - files read: 2/2 logic files
Timing analysis
- no tests changed since the last round; earlier analysis found no timing dependency.
Spec
- visible behaviour changed: none; spec searched (
rebuild_redactors) in 0038 line 264, which matches the restored re-export - verdict: not needed, test-only
Security checks
- Redaction logic untouched; no loosening.
Follow-ups
- None.
smart-ssh-coordinator
Bot
deleted the
issue-989-test-the-production-rebuild-redactors
branch
October 27, 2026 23:48
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.
Closes #989
Summary
The unit test now builds a real
AppStateand calls the productionext::rebuild_redactors_for_open_sessions. The test-only duplicate looprebuild_for_open_sessions_withis removed.Acceptance Criteria
session/tests.rs:test_ext_rebuild_redactors_for_open_sessions_touches_open_servers_only[a, a, b])tests/ext_facade.rsstill passescargo test -p app-logic(targeted) and clippy-p app-logic --all-targets: greenAssumptions
Test lives in the crate (no new production API, no new
*_tests.rs).Spec: none (test-only)
Threat model: no change – test-only, redaction logic untouched
Follow-ups: None.
🤖 Generated with Claude Code