fix(daily-security-observability): prevent step timeout downloading integrity-filtered logs#40125
Merged
Merged
Conversation
…8, fix error resilience and prompt field names Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Debug daily security observability report failure
fix(daily-security-observability): prevent step timeout downloading integrity-filtered logs
Jun 18, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the daily-security-observability workflow to prevent gh aw logs --filtered-integrity from triggering large, unbounded artifact downloads that can cause the workflow step (and runner) to time out before the agent starts. It narrows the download to only the MCP artifact set, adds an explicit CLI timeout, and hardens the step against transient failures by validating (and defaulting) the produced JSON.
Changes:
- Limit
gh aw logsdownloads to--artifacts mcpand cap runtime with--timeout 8. - Prevent step failure on transient errors/timeouts and ensure a valid
LogsDataJSON fallback viajq -e '.runs'. - Fix prompt instructions to reference
runs[].run_idand therunsarray shape.
Show a summary per file
| File | Description |
|---|---|
| .github/workflows/daily-security-observability.md | Narrows and hardens DIFC-filtered log download; updates prompt to match LogsData / RunData JSON fields. |
| .github/workflows/daily-security-observability.lock.yml | Regenerates the compiled workflow to reflect the updated download/validation logic. |
Copilot's findings
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 2/2 changed files
- Comments generated: 0
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.
gh aw logs --filtered-integritywas downloading all artifacts for every run over 7 days (no filter → gigabytes of data). The step ran ~10 min before the runner was killed; the AI agent never started.Step fix
--artifacts mcp— only the MCP gateway artifact (gateway.jsonl) is needed byrunHasDifcFilteredItems(); eliminates the bulk of the download--timeout 8— caps execution within the 60-min job budget|| true— transient API errors or a timeout exit no longer fail the stepjq -e '.runs'validity check; writes a safe empty fallback on bad/missing outputjq '.runs | length'instead ofjq '. | length'(was counting object keys, not runs)Prompt fix
databaseId→run_id—RunDataserializes the run ID asrun_id; the old name would cause the agent to look for a non-existent fieldrunsarray is empty or missing" (file is aLogsDataobject, not a bare array)