Repository navigation
fix(knowledge): backport 0.12.1 folder scan status and sync-failed notice - #33216
Conversation
) Co-authored-by: w <w@k.local> (cherry picked from commit b978d30)
) A source whose sync failed showed only a red Error badge, with nothing saying what went wrong. Keep the badge as the row's status and add a compact inline ErrorNotice under the row, with the agent hand-off on while the add form is closed, like the row's other notices. Sources store no error text, so the notice uses a fixed message, translated in all 12 locales. (cherry picked from commit fa9e328)
UX Review (Opus 5.5) — ✅ PASS (a BLOCK with no Trigger and no Outcome does not block)UX-level review of UX-Verdict: PASS cannot evaluate: missing the "Syncing" badge on a folder source mid-scan. It is one of the two states this PR exists to ship, and none of the three screenshots shows it. Evidence gaps
Notes
[UX-REVIEWED] 44938c9 Description read[DESCRIPTION-READ] af33a48d7effc2e7cbfcb55145b586a4fae1c85096b2d267026b345bf3e6d30e That sha256 names everything this verdict read: the PR description, plus the 6 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 |
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS Nothing blocks: these are backports of fixes already merged on main, and the lock-snapshot Notes
[DESIGN-REVIEWED] 44938c9 Description read[DESCRIPTION-READ] b7c4e70d1acf647db1a7faa96c270883d31dd7c28338169f4e74cf3da78812f3 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. Every item is a cherry-pick from main that fixes a status a 0.12.0 user sees today. One of those picks is missing from the description. Notes
What this change shipsInventory (6 items) — 5 justifiedIntent: bring two main fixes for Knowledge source status onto 0.12.1, so a folder scan doesn't say "Up to date" too early and a failed sync says it failed. This is a FIX.
[FIRST-PRINCIPLES-REVIEWED] 44938c9 Description read[DESCRIPTION-READ] e4f97a4a265acbf5cb882737d9f5a456156ab42d6a8f9324f74a0a3be7236a94 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 — 🔴 changes requested (blocking)GPT 6.1 found at least one blocking issue that must be resolved before merging This comment is updated in place on each push. BLOCKING -- src/kiro_crew/taskq/reconcile.py:295 -- Fence dispatch when stopped-run settlement fails
[BLOCK-MERGE] 44938c9 Adjudication (Opus 5.5) — is blocking on each finding proportionate?MEDIUM–HIGH harm. If the store refuses the write, a subagent the user stopped is run again, silently. Every condition holds in the code. A False positive or not applicable? A repository writer can comment: |
…33223) A folder scan marks the source 'error' as soon as one file fails, while the scan is still running. The row then showed the red Error badge and the "last sync failed" notice mid-scan, and the Sources list and the Knowledge page stopped polling, so the counts froze. Read an 'error' row that still reports scanning as syncing, like a 'synced' one, so polling continues and the failure shows once the scan has ended. (cherry picked from commit 02b65bc)
A source row reads as 'syncing' while its folder scan runs, but the status label table had no entry for it, so the badge showed the raw English word "syncing" in every locale. Add the status.syncing label in all 12 locales. (cherry picked from commit d924344)
Problem / Motivation
Goal: Bring the main fixes #30884 (keep a folder source syncing until its scan ends) and #33166 (say a source's sync failed under its error badge) onto
release/0.12.0for 0.12.1.Why it matters
knowledge/folder_watcher.py,website/src/pages/knowledge/SourcesList.tsxwebsite/src/pages/knowledge/SourcesList.tsxNot a goal
main; nothing is changed only here.CHANGELOG.mdchange.What changed (motivation → approach → change)
Four main commits were cherry-picked with
-xontorelease/0.12.0@80d6211963, in main order.b978d3054e7c918b3d5dfa9e328aaef843bfd9e302b65bc9db0d9611f352d92434426244938c9a03#30884 applied cleanly and keeps its author. #33166 conflicted only on context: on
mainits new lines sit next to the Bedrock KB last-search notice and itsgrant_*/last_search_*/pending_import_budgetkeys, whichrelease/0.12.0does not carry. The resolution keeps the release side and adds only #33166's own lines: thesource-sync-errornotice block inSourcesList.tsxand onesync_failed_noticekey per locale.git diff 7c918b3d5d f843bfd9e3matches main's #33166 diff line for line (15 files, +77, nothing removed).#33223 applied cleanly. It closes a case the first two picks left open: a folder scan in which one file fails marks the source
errorwhile the scan is still running, so the row showed the failure mid-scan and polling stopped. A scanningerrorrow now reads as syncing until the scan ends.#33328 applied cleanly. A scanning row's badge showed the raw English word "syncing" in every locale because the status label table had no
syncingentry; it now shows the translatedstatus.syncinglabel in all 12 locales.Backwards compatibility
Compatible: #30884 keeps the row's status at syncing while a scan runs; #33166 adds one notice and one i18n key; #33223 changes only how a scanning
errorrow displays; #33328 adds one label entry and one i18n key.Removes nothing: no setting, key or caller is removed.
Tests
Proof: not provable -- other: a backport of main commits whose proof ran on main
test/test_knowledge_source_spend.py: 17 passed.tsc --noEmit -p tsconfig.app.jsonpasses.SourcesList.syncError,SourcesListCoverage,KnowledgeUtilsCov80,KnowledgeIndexCoverage: 105 passed.src/i18n: 70 files, 1194 passed;check-i18n-stringsandgen-ui-index --checkpass.Manual verification
N/A - both fixes were verified on main; the screenshots below are the #33166 row rendering. The 0.12.1 RC soak is the end-to-end check.
Screenshots / video
The Sources list with stubbed
/api/knowledge/sources: onelocal_filesource inerror, oneurlsourcesynced, rendered from the #33166 code this PR carries. The errored row keeps its red Error badge and shows the notice with its "Ask the agent" hand-off under the row; the synced row has none.Dark, 1280 px:
Light 1280 px, dark 390 px
Related Issues
Backport to the 0.12 line for 0.12.1 of #30884, #33166, #33223 and #33328.
Sibling sweep
Siblings: none -- this PR only carries fixes already on
main.Pattern harvest
Not generalizable: this PR only carries fixes already on
main.Checklist
feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)Contribution License Agreement
Contributions are accepted under the project's Apache-2.0 license; see the Licensing section of CONTRIBUTING.md.