Skip to content

test: give the boot apply sigterm test the 30 s wait ceiling - #35625

Merged
bolichen97 merged 2 commits into
mainfrom
fix/boot-apply-test-wait-ceiling
Nov 12, 2026
Merged

bolichen97 merged 2 commits into
mainfrom
fix/boot-apply-test-wait-ceiling

Conversation

@bolichen97

Copy link
Copy Markdown
Contributor

Problem / Motivation

Goal: Give the boot apply SIGTERM test the 30 s wait ceiling so the wait-discipline ratchet stops failing backend runs on main.

#35088 added test_update_boot_apply.py's SIGTERM test with asyncio.wait_for(..., timeout=10). test_wait_discipline_ratchet.py scans the whole tree and refuses a wait_for under 30 s in a test, so it fails on any backend run that includes it.

Why it matters

Every PR's backend shard that runs the ratchet goes red on a line it did not touch.

Not a goal

  • No product change; the wait only bounds a test that waits on an Event.

What changed (motivation → approach → change)

timeout=10 becomes timeout=30 on that one wait_for; it still waits on the Event the fake child sets.

Backwards compatibility

Test only.

Tests

test_wait_discipline_ratchet.py (53 passed) and test_update_boot_apply.py pass locally.

Proof: not provable -- other: a test-only ceiling change

Manual verification

N/A: test only.

Screenshots / video

N/A: no visual change.

Related Issues

Follow-up to #35088.

Pattern harvest

Not generalizable: one test line the ratchet already catches.

Checklist

  • At most two commits, with a Conventional Commits title
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

Contribution License Agreement

Contributions are accepted under the project's Apache-2.0 license; see the Licensing section of CONTRIBUTING.md.

@bolichen97
bolichen97 requested review from a team and KiroCrewCaptain as code owners November 11, 2026 22:15
@github-actions github-actions Bot added the readiness: checking Automated validation is still running label Nov 11, 2026
@github-actions

github-actions Bot commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

UX Review (Opus 5.5) — ⏭️ skipped

Revision 66952992af389f2e9a2fd16c700b7a878e2a411a touches no user-facing surface (no changes under website/ or committed screenshots), so the UX review was skipped. Does not block merge.

@github-actions

github-actions Bot commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5) — ✅ PASS

Premise-level review of 66952992af389f2e9a2fd16c700b7a878e2a411a — why this exists and whether the shipped surface is the smallest honest version. Updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

First-Principles-Verdict: PASS

Both items unwedge red checks on main. The test fix uses the repository's own await_until helper instead of adding a new spelling.

What this change ships

Inventory (2 items) — 1 justified

Intent: stop two tests that already fail on main from turning every backend run red. This is a FIX.

  1. The boot-apply SIGTERM test now waits for the fake child through await_until instead of a 10 s wait_for. The description says "timeout=10 becomes timeout=30" — justified
  2. The updates handler facade's type-checking block now names _running_version, so test_updates_handlers_facade passes again — undeclared (in the commit message only, not the description)

[FIRST-PRINCIPLES-REVIEWED] 6695299

Description read

[DESCRIPTION-READ] e6d0b94c32f0427a65fc0149b7c63cc3a385c4df3c03b47bf8fbcb6fff272c62

That sha256 names the PR description this verdict read. Recompute it with .github/scripts/pr-description-capture.sh; if it differs, the description changed after this verdict was formed and any finding drawn from the description is unproven.

@github-actions

github-actions Bot commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5) — ✅ PASS

Design-level review of 66952992af389f2e9a2fd16c700b7a878e2a411a — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

Design-Verdict: PASS

Both changes are confined to a test and a block that only runs under type checking. Nothing at runtime changes and nothing is taken away.

Notes

  • The diff and the description don't match. The description says "timeout=10 becomes timeout=30", but the diff swaps in await_until(started, ...), which bounds the wait at half the test's own timeout, not 30 s. The description also never mentions the updates.py hunk (_running_version added under type checking), which the head commit's own message names. Update "What changed" so the description accounts for both hunks.

[DESIGN-REVIEWED] 6695299

Description read

[DESCRIPTION-READ] af6c8c24aeb5e13c710a10a65a81a283e7e93a2fb71f22d19e0a5df466489e7d

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Opus 5.5 Review — ✅ no blocking findings

Reviewed 66952992af389f2e9a2fd16c700b7a878e2a411a — this comment is updated in place on each push.

Review details

No findings.

[OPUS-REVIEWED] 6695299

Verdict parsed from the review's SHA-scoped output markers for commit 66952992af389f2e9a2fd16c700b7a878e2a411a.

False positive or not applicable? A repository writer can comment:
/ai-review override fable 66952992af389f2e9a2fd16c700b7a878e2a411a false-positive: <reason, 20 to 500 characters>

@bolichen97
bolichen97 enabled auto-merge (squash) November 11, 2026 22:17
@github-actions

github-actions Bot commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

GPT 6.1 Review — ✅ no blocking findings

GPT 6.1 completed its review of 66952992af389f2e9a2fd16c700b7a878e2a411a and found no blocking issues.

This comment is updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] 6695299

False positive or not applicable? A repository writer can comment:
/ai-review override gpt 66952992af389f2e9a2fd16c700b7a878e2a411a false-positive: <reason, 20 to 500 characters>

buluoray
buluoray previously approved these changes Nov 11, 2026

@buluoray buluoray left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 Kiro Crew Auto-Pipeline [operator: buluoray]:

Approve at 5045dcf. Together with #35614 this turns main's backend tests green again.

Main is red since #35088: test_wait_discipline_ratchet.py fails on Backend Tests (3.12, 5) and (Windows) (2) with a short fixed wait is back under test/ with no baseline line: ['test/test_update_boot_apply.py:335 wait_for(10s)'].

Checked: I merged this PR and #35614 onto current main (e8283ce) and ran test_update_boot_apply.py, test_wait_discipline_ratchet.py and test_updates_handlers_facade.py: 81 passed.

The change raises one wait_for ceiling from 10 s to 30 s. The test still waits on the started event, so it does not get slower when it passes; the ceiling only bounds a hang. Test-only.

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Nov 11, 2026
The wait-discipline ratchet refuses a short wait_for in a test. The
SIGTERM test now awaits the Event its fake child sets with await_until,
whose bound is the test's lost-run ceiling, instead of a fixed literal.
@bolichen97

Copy link
Copy Markdown
Contributor Author

Two commits now, both clearing breaks #35088 left on main, because each one keeps the other's backend shard red on its own:

  1. The SIGTERM test awaits its fake child's Event with kiro_crew.testing.wait.await_until instead of a fixed wait_for literal (GPT's finding: no raised literal; the bound is the test's lost-run ceiling).
  2. updates.py's type-checking block names _running_version, which updates_step_up.py serves since fix(updates): never restart a running gateway; apply at the next start #35088; test_updates_handlers_facade.py fails on main without it (Backend Tests (3.12, 4) and Windows (4) here).

test_update_boot_apply.py (19), test_updates_handlers_facade.py (9) and test_wait_discipline_ratchet.py (53) pass locally. The same two fixes are on release/0.12.0 in b659923.

AI-assisted, sent by Kiro Crew Captain

@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Nov 11, 2026
@buluoray

Copy link
Copy Markdown
Contributor

🤖 Kiro Crew Auto-Pipeline [operator: buluoray]:

Carrying both fixes here is the right call: #35614 alone cannot go green, because its shard 5 still fails on the wait ratchet this PR fixes.

One thing keeps this head (9dc770b) red: Backend Lint & Type Check (3.12) fails with src/kiro_crew/dashboard/handlers/updates.py Imports are incorrectly sorted and/or formatted. It is the new from kiro_crew import __version__ as _running_version line. #35614 placed the same line last in that block and marked it # noqa: F401 # isort: skip, and its lint job passes. Either that marker, or moving the line to where isort wants it, should clear it.

The push dismissed my approval. I will re-review as soon as the lint job is green on a new head.

@tim-finnigan

Copy link
Copy Markdown
Contributor

Coverage Gate was still red on this one's head (gateway_restart.py and update_boot_apply.py below the 80% per-file floor, from #35088). #35725 adds the tests against main.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants