fix(bk-annotations): silence trace noise on empty-kind phase markers#1099
Draft
gregmagolan wants to merge 1 commit into
Draft
fix(bk-annotations): silence trace noise on empty-kind phase markers#1099gregmagolan wants to merge 1 commit into
gregmagolan wants to merge 1 commit into
Conversation
`setup_phase` and `preflight_phase` emit TaskUpdates with `kind=""` — that's the documented "no template" contract (see `lib/lifecycle.axl`) for phase-marker dispatches that telemetry observers consume but renderable surfaces have no per-kind data for. The BK annotation handler was tracing every such update twice — once for the missing context_id (when setup_phase runs before task_started) and once for the missing renderer (when preflight_phase runs after). Both lines fired on every lint task in debug logs. Hoist the decision into a shared `should_render_update(update, context_id)` helper returning `(decision, reason)`. Empty kind is silent (it's expected). `no_context_id` / `unknown_kind` keep their trace because those are real routing/config bugs worth surfacing under `ASPECT_DEBUG=1`. Regression test: `test-bk-annotation-decision` asserts each skip reason and the happy path for every registered renderer. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
✨ Aspect Workflows Tasks📅 Tue May 19 11:53:34 UTC 2026 ❌ 1 failed task
✅ 14 successful tasks
🔁 Reproduce❌ format (buildifier-gha-debug)🛠️ Fix❌ format (buildifier-gha-debug)⏱ Last updated Tue May 19 12:00:10 UTC 2026 · 📊 GitHub API quota 872/15,000 (6% used, resets in 55m) |
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.
The
lint,format,gazelle, anddeliverytask debug logs were spamming two trace lines on every run:Both come from
setup_phase/preflight_phase(inlib/lifecycle.axl) emittingTaskUpdate(kind="")— that's the documented "no template" contract for phase markers that telemetry observers should see but renderable surfaces have nothing to render.The BK annotation handler treated empty kind the same as an unknown kind (a real misconfig) and traced both. Now: empty kind returns silently (it's the contract);
no_context_id/unknown_kindstill trace because those are routing/config bugs.The decision is hoisted into a shared
should_render_update(update, context_id) -> (decision, reason)helper so the contract is testable and regression-guarded.Changes are visible to end-users: yes
Suggested release notes
Buildkite annotations: no renderer for kind=""andtask_update fired but no context_idtrace lines from--debugoutput on every task run; the underlying empty-kind phase markers were always the intended "no template" case.Test plan
aspect dev test-bk-annotation-snapshots)aspect dev test-bk-annotation-decision)