Skip to content

fix(daily-security-observability): pre-download firewall runs to avoid MCP tool timeout - #48988

Merged
pelikhan merged 2 commits into
mainfrom
copilot/fix-missing-tools-report
Jul 29, 2026
Merged

fix(daily-security-observability): pre-download firewall runs to avoid MCP tool timeout#48988
pelikhan merged 2 commits into
mainfrom
copilot/fix-missing-tools-report

Conversation

Copilot AI commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

The agenticworkflows logs MCP tool call with firewall:true, start_date:-7d consistently exceeds the gateway's 60-second per-tool RPC deadline — downloading the activation artifact (needed to check aw_info.json for firewall detection) across ~100 runs takes longer than the gateway allows, causing Phase 1/2 of the report to fail entirely.

Changes

  • New pre-download step — "Download firewall-enabled workflow runs" runs before the agent, mirroring the existing integrity-filtered logs pattern:

    gh aw logs --firewall --start-date -7d --json -c 100 \
      --artifacts activation --timeout 8 \
      > /tmp/gh-aw/agent/firewall/firewall-enabled-runs.json || true

    Uses --artifacts activation to download only the minimal artifact required for firewall detection, with an 8-minute step timeout instead of the MCP's 60-second limit. Falls back to an empty dataset on failure.

  • Phase 1.1 prompt update — replaced the logs MCP tool call with a read from the pre-downloaded file at /tmp/gh-aw/agent/firewall/firewall-enabled-runs.json.

  • Recompiled .lock.yml for all 266 workflows.

…daily-security-observability

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix missing tools in daily security observability report fix(daily-security-observability): pre-download firewall runs to avoid MCP tool timeout Jul 29, 2026
Copilot AI requested a review from pelikhan July 29, 2026 22:20
@pelikhan
pelikhan marked this pull request as ready for review July 29, 2026 22:22
Copilot AI review requested due to automatic review settings July 29, 2026 22:22
@pelikhan
pelikhan merged commit a9ee388 into main Jul 29, 2026
1 check passed
@pelikhan
pelikhan deleted the copilot/fix-missing-tools-report branch July 29, 2026 22:22

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Moves firewall-run discovery out of the MCP call to avoid its 60-second deadline.

Changes:

  • Pre-downloads firewall-enabled runs with activation artifacts.
  • Reads the downloaded JSON during analysis.
  • Regenerates the compiled workflow.
Show a summary per file
File Description
.github/workflows/daily-security-observability.md Adds pre-download logic and updates the analysis prompt.
.github/workflows/daily-security-observability.lock.yml Compiles the new workflow step and prompt.

Review details

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comments suppressed due to low confidence (1)

.github/workflows/daily-security-observability.md:129

  • Give this scan a separate logs output directory. Both pre-download commands currently use the default .github/aw/logs, and the integrity scan writes run_summary.json caches there from the mcp artifact. For a run that has both DIFC events and firewall enabled, this second scan accepts that summary as a cache hit without considering the newly requested artifact set, never downloads activation, and then --firewall skips the run because aw_info.json is absent. A dedicated -o path prevents those false negatives.
      gh aw logs --firewall --start-date -7d --json -c 100 \
  • Files reviewed: 2/2 changed files
  • Comments generated: 2
  • Review effort level: Medium

Comment on lines +129 to +131
gh aw logs --firewall --start-date -7d --json -c 100 \
--artifacts activation --timeout 8 \
> "$FIREWALL_RUNS" || true
"count": 100
}
```
Read the pre-downloaded list of firewall-enabled workflow runs from `/tmp/gh-aw/agent/firewall/firewall-enabled-runs.json`. This file was populated by the startup step and contains runs from the last 7 days with the firewall feature enabled. Extract the `run_id` from each entry in the `runs` array.
@github-actions

Copy link
Copy Markdown
Contributor

🎉 This pull request is included in a new release.

Release: v0.84.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[aw] Daily Security Observability Report is missing required tool

3 participants