Repository navigation
fix: say when a failed frontend build wrote no log - #34047
Conversation
UX Review (Opus 5.5) — ⏭️ skippedRevision |
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS Nothing blocks. It changes only message text: a failed build with no log now says so and gives the commands to run by hand, and the CLI says "see the log above" only when a log tail was printed. Notes
[DESIGN-REVIEWED] 5cbba1d Description read[DESCRIPTION-READ] bae7324be010391c5a46d7ddfdacef00640280fd2cc90c3281b2c3538424aa6c 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 |
First Principles Review (Opus 5.5) — ✅ PASSPremise-level review of First-Principles-Verdict: PASS Nothing blocks. Each item fixes a message that pointed a log-less failed build at a log that does not exist (#32737). What this change shipsInventory (4 items) — 4 justifiedIntent: when a dashboard build fails and wrote no log, the user is told that no log exists and how to see the npm output. This is a FIX.
[FIRST-PRINCIPLES-REVIEWED] 5cbba1d Description read[DESCRIPTION-READ] 437711fc92379268c4b5a27f1cfef2e710cf9f433bd165013bf625cf92bd32cd That sha256 names the PR description this verdict read. Recompute it with |
Opus 5.5 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
GPT 6.1 Review — ✅ no blocking findingsGPT 6.1 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
buluoray
left a comment
There was a problem hiding this comment.
Approved at 1e2fef2. A failed dashboard build with no log (always on Windows, or a refused log destination on POSIX) now says no log was written and to run npm ci / npm run build in website/ (src/kiro_crew/frontend.py:487-491). The CLI's "see the log above" prints only when a tail was printed (src/kiro_crew/cli_server_update.py:618-619). Message/doc text only; nothing changes when a log exists. GPT, Opus, UX and Security Scope pass. Backend 3.12 shard 7 is the known timing flake #28212 (test_the_scan_is_linear_not_quadratic), and Coverage Gate follows it.
Pull request was closed
Where no pinned directory walk exists (Windows) the update's frontend build opens no log and discards the npm output by design, but a failed build then printed only the bare sentence and the CLI still said "see the log above". The failure now says no build log was written and to run npm ci and npm run build in website/ to see the output, and the CLI points at the log only when a tail was printed. The install guide and the cli and gateway specs say the same. Closes #32737
1e2fef2 to
5cbba1d
Compare
|
Rebased: main moved in docs/guides/install.md, docs/system-specs/modules/cli.md, src/kiro_crew/cli_server_update.py, src/kiro_crew/frontend.py, test/test_cli_server_more_coverage.py and the gateway spec since this head's CI ran (69d3a9a -> dcd4830); CI re-running. The new base carries #34537, the fix for the [operator: bolichen97] |
KiroCrewCaptain
left a comment
There was a problem hiding this comment.
Tier 1 auto-approve: fix (7 files). Criteria: no conflict, no requested changes, security path denylist clean, design-doc gate clean, security checklist all-NO, no reviewer-lane findings, readiness signal fresh for this head SHA, declared category matches the diff. Category: a failed frontend build with no log file now says no log was written and how to see the npm output, instead of pointing at a log that does not exist; adds tests. Spec files changed as a ride-along (a minority of the diff on both file count and changed lines), not reviewed as a design decision: docs/system-specs/modules/cli.md, docs/system-specs/modules/slack-gateway.md.
Problem / Motivation
Goal: A source-install user whose update's dashboard build fails on Windows is told that no build log was written and how to see the npm output, instead of being pointed at a log that does not exist.
On Windows
kirocrew update(and the dashboard Update button and the gateway's auto-apply) opens no build log, by design: the safe open oflogs/frontend-build.logneeds a pinned directory walk that Windows does not have. When the build then failed, the message was only "Frontend build did not complete — the dashboard still serves the previous bundle", the CLI added "see the log above" with nothing above it, anddocs/guides/install.mdpromised a log file.Why it matters
A Windows source-install user whose update build fails is sent to a log that does not exist, and nothing tells them the npm output was never kept. Finding the cause means guessing that they must rerun
npm ciandnpm run buildinwebsite\by hand.Not a goal
logs/frontend-build.log, or the stop before restart.What changed (motivation → approach → change)
A failed build with no log now says so and says how to see the output, and the CLI only points at "the log above" when a log tail was printed above it.
FrontendBuildResult.failure_message()infrontend.py(CLI, dashboard progress card, auto-apply)Frontend build did not complete — the dashboard still serves the previous bundle. No build log was written; run `npm ci` and `npm run build` in website/ to see the npm outputkirocrew updatehint incli_server_update.pyDo not restart the gateway until the dashboard builds; see the log above.Do not restart the gateway until the dashboard builds.With a log open (POSIX), both lines are unchanged. The new sentence shows wherever no log was opened: always on Windows, and on POSIX when the log destination is refused.
docs/guides/install.md, thebuild_frontend_syncdocstring and thecliandslack-gatewayspecs say the same.Backwards compatibility
Compatible: only message and doc text change; with a log open (POSIX) every printed line is the same as before.
Removes nothing: no path, key, record or function is removed; the CLI drops its "see the log above" pointer only when no log tail was printed.
Tests
test/test_frontend_build_log.py::test_a_failure_with_no_log_says_so_and_how_to_see_the_output: afailedresult with no log says no build log was written and namesnpm ciandnpm run buildinwebsite/.test/test_cli_server_more_coverage.py::TestUpdateGitPath::test_frontend_build_failure_without_a_log_points_at_no_log:kirocrew updatewith a failed, log-less build exits 1 and does not print "see the log above".TestUpdateGitPath::test_frontend_build_failure_installs_then_exitsalso pins that the pointer stays when a tail was printed.Proof: PROVEN test/test_cli_server_more_coverage.py::TestUpdateGitPath::test_frontend_build_failure_without_a_log_points_at_no_log, test/test_frontend_build_log.py::test_a_failure_with_no_log_says_so_and_how_to_see_the_output (head 5cbba1d)
Manual verification
N/A — unit coverage sufficient: the Windows branch is the
pinned_fs.supports_pinned_walk()capability, which the existing tests already force off on Linux; no Windows run was made.Screenshots / video
N/A — the diff touches no frontend file; the changed text is a CLI line and the backend failure string, shown verbatim in the table above.
Related Issues
Closes #32737
Sibling sweep
Swept: git grep -n "failure_message()" -- src/kiro_crew
Swept: git grep -n "see the log above" -- src/kiro_crew
Sibling: src/kiro_crew/dashboard/handlers/updates_apply.py:928 -- not affected -- it shows failure_message(), which now carries the no-log sentence
Sibling: src/kiro_crew/slack/gateway_runtime/update_apply.py:950 -- not affected -- it shows failure_message(), which now carries the no-log sentence
Sibling: src/kiro_crew/cli_server_update.py:168 -- not affected -- the policy update command's own output is printed above that line
Pattern harvest
Not generalizable: one hint pointed at output that only the POSIX branch produces, and its only consumer is fixed here.
Checklist
feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)