Skip to content

Fix AWF tool-cache mounting so Daily News Copilot can start in chroot#36900

Open
Copilot wants to merge 2 commits into
mainfrom
copilot/aw-fix-daily-news-failure
Open

Fix AWF tool-cache mounting so Daily News Copilot can start in chroot#36900
Copilot wants to merge 2 commits into
mainfrom
copilot/aw-fix-daily-news-failure

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Jun 4, 2026

Daily News failed with a Copilot engine startup error (“terminated before producing output”). The failing run showed AWF chroot could not find node, even though Node was installed via runner tool cache.

  • Root cause

    • AWF command generation only mounted RUNNER_TOOL_CACHE when it was not under /opt/*.
    • On hosted runners (/opt/hostedtoolcache), this skipped the mount, so node was unavailable inside chroot.
  • AWF command generation update

    • Updated shared AWF helper logic to always mount RUNNER_TOOL_CACHE when it exists, including /opt/hostedtoolcache.
    • Kept existing fallback to /home/runner/work/_tool when RUNNER_TOOL_CACHE is absent.
  • Daily News lockfile update

    • Applied the generated mount probe change in daily-news.lock.yml for both Copilot AWF invocations so runtime behavior matches the helper fix.
  • Regression guard

    • Tightened the AWF command test to assert we no longer emit the /opt/* exclusion branch and still emit mount injection.
GH_AW_TOOL_CACHE_MOUNT=""
GH_AW_TOOL_CACHE="${RUNNER_TOOL_CACHE:-/opt/hostedtoolcache}"
if [ -d "$GH_AW_TOOL_CACHE" ]; then
  GH_AW_TOOL_CACHE_MOUNT="$GH_AW_TOOL_CACHE:$GH_AW_TOOL_CACHE:ro"
elif [ -d "/home/runner/work/_tool" ]; then
  GH_AW_TOOL_CACHE_MOUNT="/home/runner/work/_tool:/home/runner/work/_tool:ro"
fi

pr-sous-chef: update branch requested for run https://github.com/github/gh-aw/actions/runs/26979726834

Generated by 👨‍🍳 PR Sous Chef · gpt54mini 3.6M ·


Generated by 👨‍🍳 PR Sous Chef · gpt54mini 4M ·

Copilot AI linked an issue Jun 4, 2026 that may be closed by this pull request
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix daily news workflow engine failure Fix AWF tool-cache mounting so Daily News Copilot can start in chroot Jun 4, 2026
Copilot AI requested a review from pelikhan June 4, 2026 13:06
@pelikhan pelikhan added the awf label Jun 4, 2026
@pelikhan
Copy link
Copy Markdown
Collaborator

pelikhan commented Jun 4, 2026

@lpcox @salmanmkc self hosted issues on NVIDIA image

@lpcox lpcox marked this pull request as ready for review June 4, 2026 17:03
Copilot AI review requested due to automatic review settings June 4, 2026 17:03
@lpcox lpcox added the smoke label Jun 4, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes AWF chroot startup failures on hosted runners by ensuring the runner tool cache (e.g., /opt/hostedtoolcache) is always mounted into the AWF environment when present, so node (and other toolcache-provided runtimes) are available inside the chroot.

Changes:

  • Updated AWF command generation to always mount RUNNER_TOOL_CACHE when it exists (including /opt/hostedtoolcache).
  • Updated daily-news.lock.yml to apply the same mount-probe logic for both Copilot AWF invocations.
  • Tightened the AWF command unit test to assert the /opt/* exclusion branch is no longer emitted.
Show a summary per file
File Description
pkg/workflow/awf_helpers.go Removes the /opt/* skip so the detected tool cache is always mounted read-only when present.
pkg/workflow/awf_config_test.go Updates assertions to require mounting the detected tool cache path and to forbid the removed exclusion branch.
.github/workflows/daily-news.lock.yml Syncs the workflow’s embedded mount probe with the helper behavior for both Copilot executions.

Copilot's findings

Tip

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

  • Files reviewed: 3/3 changed files
  • Comments generated: 0

@github-actions github-actions Bot mentioned this pull request Jun 4, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 4, 2026

@copilot please summarize the remaining blockers after the branch refresh and rerun the checks if needed.

Generated by 👨‍🍳 PR Sous Chef · gpt54mini 4M ·

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[aw] Daily News failed

4 participants