Repository navigation
test(workers): cover scheduler negative matrix (replacement) - #412
Conversation
Test-First: src-tauri/src/workers.rs::dispatch_once_refuses_each_missing_gate_without_spawning Test-First: src-tauri/src/workers.rs::scheduler_dispatch_requires_the_test_only_permit Test-First: src-tauri/src/workers.rs::concurrent_dispatch_starts_one_worker_and_refuses_stale_writer Test-First: src-tauri/src/workers.rs::dependency_matrix_launches_only_fully_satisfied_task Regression-For: 939c7e9 Regression-For: 55f7857 No-Test: make the commit-msg candidate test pipefail-safe; runtime behavior is unchanged Co-Authored-By: Codex GPT-5 <47299143+Cuarroc@users.noreply.github.com>
Test-First: src-tauri/src/workers.rs::dispatch_once_refuses_truncated_dependency_set Regression-For: 55f7857 Co-Authored-By: Codex GPT-5 <47299143+Cuarroc@users.noreply.github.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 130ef90536
ℹ️ 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".
| #[tokio::test] | ||
| async fn dispatch_once_refuses_truncated_dependency_set() { |
There was a problem hiding this comment.
Ersetze den Commit durch einen mit Red-first-Trailern
Dieser Commit fügt mehrere Rust-Tests hinzu und ändert ein CI-Skript, enthält aber weder einen Test-First:-/Regression-For:- noch einen No-Test:-Trailer. Der Lauf BASE_SHA=9fd9f3e^ HEAD_SHA=9fd9f3e bash scripts/ci/red-first.sh --plan endet deshalb mit Exit 1 und meldet ausdrücklich „aendert Quellcode ohne Test-First:/Regression-For:/No-Test:“, sodass dieser Kandidat die vorgeschriebene Red-first-Prüfung nicht bestehen kann und mit korrekten Trailern neu erstellt werden muss.
AGENTS.md reference: AGENTS.md:L167-L170
Useful? React with 👍 / 👎.
| } | ||
| } | ||
|
|
||
| async fn seed_dispatch_case( |
There was a problem hiding this comment.
Teile das S-Paket auf höchstens 150 Diffzeilen
M4-R7-02 ist in docs/PLAN.md:155 als Größe S eingestuft, dieser Commit umfasst jedoch 282 Diffzeilen (281 Ergänzungen und eine Löschung) und überschreitet damit die in docs/PLAN.md:237 festgelegte S-Grenze von 150 Zeilen einschließlich Tests deutlich. Das Paket muss vor der Integration aufgeteilt oder vom Koordinator im Plan neu eingestuft werden.
AGENTS.md reference: AGENTS.md:L13-L15
Useful? React with 👍 / 👎.
| let stale = fx | ||
| .store | ||
| .checkpoint_continuous_task("due-task", loser, 1, Some("running"), None) | ||
| .await |
There was a problem hiding this comment.
Prüfe einen tatsächlich veralteten Fence
Wenn die Checkpoint-Prüfung künftig nur noch den aktuellen Owner, aber nicht mehr den Fence validiert, bleibt dieser Test grün: Der Aufruf verwendet den vollständig anderen loser-Owner und Fence 1, sodass bereits die Owner-Prüfung ihn als „unauthorized“ ablehnt. Damit belegt der Test trotz seines Namens keinen stale-Fence-Fall desselben Owners; ergänze einen Schreibversuch mit dem berechtigten Owner und einem veralteten Fence, damit die geforderte Concurrency-Regression wirklich erkannt wird.
AGENTS.md reference: AGENTS.md:L87-L89
Useful? React with 👍 / 👎.
| let source = include_str!("workers/scheduler.rs"); | ||
| assert!(source.contains("pub struct SchedulerPermit(());")); | ||
| assert!(source.contains("#[cfg(test)]\npub(super) fn test_permit()")); | ||
| assert!(source.contains("_permit: &SchedulerPermit")); | ||
| assert!(!source.contains("pub fn permit()")); |
There was a problem hiding this comment.
Sichere alle Produktionskonstruktoren des Permits ab
Wenn versehentlich ein Produktionskonstruktor mit einem anderen Namen hinzukommt, etwa SchedulerPermit::new() oder eine öffentliche Konstante, bleibt dieser Test grün, weil er ausschließlich nach dem exakten Text pub fn permit() sucht. Dadurch schützt der neue Regressionstest die behauptete Test-only-Grenze nicht; verwende eine strukturelle beziehungsweise Compile-fail-Prüfung, die jeden außerhalb von #[cfg(test)] erreichbaren Konstruktionspfad erkennt, solange die Scheduler-Aktivierung eingefroren ist.
AGENTS.md reference: AGENTS.md:L125-L130
Useful? React with 👍 / 👎.
|
Queued — the merge queue status continues in this comment ↓. |
|
@Mergifyio queue |
Merge Queue Status
This pull request spent 11 minutes 20 seconds in the queue, including 11 minutes 6 seconds running CI. ReasonThe merge conditions cannot be satisfied due to failing checks
Failing checks: HintYou may have to fix your CI before adding the pull request to the queue again. Waiting for
All conditions
Requeued — the merge queue status continues in this comment ↓. |
Regression-For: b4b2a17 Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
|
@Mergifyio queue |
Merge Queue Status
This pull request spent 13 minutes 45 seconds in the queue, including 12 minutes 34 seconds running CI. Required conditions to merge
|
Dieses Paket prüft, dass der Scheduler ohne erfüllte Schranken keinen Worker startet.
Es belegt außerdem den Schutz gegen Doppelstarts, veraltete Schreibrechte und unvollständige Abhängigkeiten.
Produktionscode wurde nicht geändert.
Report
Windows fix: CRLF-normalized source assertions (queue run 37245521200)
What changed
Evidence
npm run dev:start-check— exit 0 before builds; 11.4 GB free and one cargo build running, within the server limit. Provider usage file was not supplied.cargo test --manifest-path src-tauri/Cargo.toml workers::tests:: -- --list— exit 0; exact new Rust test names observed.bash scripts/ci/red-first.sh --plan— exit 0; 8 evidence items and 5 test specs.bash scripts/ci/gates.sh lane prepush— exit 0; 1,793 Rust tests passed, 7 skipped; log:/tmp/projecta-m4-r7-02-prepush-final.log.git push -u origin codex/m4-r7-02-negative-matrix-b— exit 0; the foreground pre-push hook completed the full lane.git ls-remote origin refs/heads/codex/m4-r7-02-negative-matrix-b— exit 0; remote SHA equals the candidate SHA.NICHT ABGEDECKT
#[cfg(windows)]tests or the Windows clippy arms; the Windows lane runs in the merge queue.Review
Review: Stufe B abgeschlossen (Claude Sonnet 5.5), Kandidat 130ef90.
Review disposition
red-first.sh --planexit 0, count=8, specs=5), CI (all checks pass), architecture drift (no production code, no new pattern).src-tauri/src/workers.rstruncated-dependency test):dispatch_once_refuses_truncated_dependency_setoverlaps thetruncatedrow ofdependency_matrix_launches_only_fully_satisfied_task. Rejected: the standalone test is the named Test-First/Regression-For target for the store regression; removing it would invalidate the pushed trailer.scheduler_dispatch_requires_the_test_only_permit): source-string assertions are brittle against refactors. Rejected: the permit has no runtime branch to test; a failing assertion is a deliberate prompt to re-review the permit boundary.concurrent_dispatch_starts_one_worker_and_refuses_stale_writer): the stale-writer check would also reject an owner that never claimed; the exclusivity itself is proven by the exactly-one-Ok and one-spawn assertions. Rejected: no gap in the claimed guarantee.Open points