Conversation
Alert grouping runs per channel, so one root cause that spans several services or channels arrives as several incidents opened within minutes of each other. The bundled fault-analysis script fetched six aspects of the given incident and never looked sideways at its neighbours. Add a seventh section: read start_time from `incident detail --json`, then list every incident in the account (any channel, any progress) that started within +/-15 minutes of it, projected to the fields needed to spot a shared factor. Both GNU and BSD date are handled; when start_time cannot be read the section prints a SKIPPED marker with the manual command instead of failing the whole fetch. Update the incident card and the SKILL.md router line to describe the seventh read and how to interpret it: a shared factor is a hypothesis to test against alerts and changes, not a conclusion; a list cut at --limit means a storm; merging stays a human decision.
The fake fduty now answers `--json` calls with a fixed start_time so the seventh section runs: assert the eight invocations, the exact ±15 min window passed to `incident list`, and that the other reads still use their compact defaults. A second case drops start_time and checks the section prints its SKIPPED marker with the manual command instead.
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.
What
The bundled fault-analysis script (
skills/flashduty/scripts/incident-summary.sh) fetched six aspects of the given incident and never looked sideways at its neighbours. Alert grouping runs per channel, so one root cause spanning several services or channels arrives as several incidents opened within minutes of each other.This adds a seventh section that lists every incident in the account started within ±15 min of the given one (any channel, any progress), projected to
incident_id,num,title,incident_severity,progress,start_time,channel_idin toon output.How
start_timeis read fromincident detail <id> --json(works on current and older CLI builds); GNU and BSDdateare both handled when converting it to a unix timestamp.start_timecannot be read, the section prints aSKIPPEDmarker with the manual command instead of failing the whole fetch.reference/incident.mdgains the ⑦ line in the manual list and a "Reading ⑦" paragraph: a shared factor is a hypothesis to test against alerts and changes, not a conclusion; a list cut at--limitmeans a storm;incident mergeremains a human decision.SKILL.mdrouter line updated to "seven reads".Checks
bash -non the script.go run ./internal/cmd/skilldoc check→ cards OK.