Skip to content

Fix TestRuntimeSetupPreservesUserVersions false positive from AWF version#14221

Merged
pelikhan merged 4 commits intomainfrom
copilot/fix-github-actions-workflow-3eb85ab4-04b4-4d43-8eb1-dd06211f2ce3
Feb 6, 2026
Merged

Fix TestRuntimeSetupPreservesUserVersions false positive from AWF version#14221
pelikhan merged 4 commits intomainfrom
copilot/fix-github-actions-workflow-3eb85ab4-04b4-4d43-8eb1-dd06211f2ce3

Conversation

Copy link
Contributor

Copilot AI commented Feb 6, 2026

Test TestRuntimeSetupPreservesUserVersions was failing after AWF bump to v0.13.12. The test used strings.Contains(lockContent, "3.12") to detect if default Python 3.12 was incorrectly added, but this matched AWF version "0.13.12" in the compiled workflow.

Change
Updated test to check for explicit Python version declarations:

// Before: Matched any "3.12" substring including "0.13.12"
if strings.Contains(lockContent, "3.12") {
    t.Error("Should not override user's version with default version")
}

// After: Only matches Python version field
if strings.Contains(lockContent, `python-version: '3.12'`) || strings.Contains(lockContent, `python-version: "3.12"`) {
    t.Error("Should not override user's version with default version")
}

The test now correctly validates user-specified Python versions are preserved without false positives from unrelated version strings.

Original prompt

Fix the failing GitHub Actions workflow Integration: Workflow Runtime & Setup
Analyze the workflow logs, identify the root cause of the failure, and implement a fix.
Job ID: 62797624261
Job URL: https://github.com/github/gh-aw/actions/runs/21764804244/job/62797624261


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI and others added 2 commits February 6, 2026 20:38
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix failing GitHub Actions workflow for integration setup Fix TestRuntimeSetupPreservesUserVersions false positive from AWF version Feb 6, 2026
Copilot AI requested a review from pelikhan February 6, 2026 20:43
@pelikhan pelikhan marked this pull request as ready for review February 6, 2026 20:46
Copilot AI review requested due to automatic review settings February 6, 2026 20:46
@pelikhan pelikhan merged commit 13f61dd into main Feb 6, 2026
51 checks passed
@pelikhan pelikhan deleted the copilot/fix-github-actions-workflow-3eb85ab4-04b4-4d43-8eb1-dd06211f2ce3 branch February 6, 2026 20:47
Copy link
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

Updates integration tests and generated workflow artifacts/lockfiles to align with the AWF v0.13.12 bump and avoid test false-positives caused by unrelated version strings in compiled workflow output.

Changes:

  • Tighten TestRuntimeSetupPreservesUserVersions assertions to look for explicit python-version declarations rather than a generic "3.12" substring.
  • Bump AWF versions/tags in workflow lockfiles from v0.13.7 / 0.13.7 to v0.13.12 / 0.13.12.
  • Regenerate specs/artifacts.md to reflect updated workflow inventory and artifact paths (including /tmp/gh-aw/agent/).

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.

File Description
pkg/workflow/runtime_setup_integration_test.go Fixes the failing runtime setup integration test by using a more specific match for the default Python version.
.github/workflows/dependabot-project-manager.lock.yml Updates AWF binary/image tags to v0.13.12 in the locked workflow.
.github/workflows/daily-cli-tools-tester.lock.yml Updates AWF binary/image tags to v0.13.12 in the locked workflow.
specs/artifacts.md Regenerates artifact location reference to include current workflow usage and paths.

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

Comment on lines +297 to 300
// Should not add default version (3.12) - check specifically for python-version to avoid
// false positives from other version strings like AWF version "0.13.12"
if strings.Contains(lockContent, `python-version: '3.12'`) || strings.Contains(lockContent, `python-version: "3.12"`) {
t.Error("Should not override user's version with default version")
Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

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

The negative assertion only checks for quoted forms of 3.12. If the lockfile emitter ever outputs python-version: 3.12 (unquoted) this test would miss the regression. Consider matching python-version: with optional quotes/whitespace (e.g., via regexp) and/or reusing the non-comment-line helpers so the check is robust to YAML formatting changes.

Copilot uses AI. Check for mistakes.
Comment on lines 140 to +143
- name: Install GitHub Copilot CLI
run: /opt/gh-aw/actions/install_copilot_cli.sh 0.0.405
- name: Install awf binary
run: bash /opt/gh-aw/actions/install_awf_binary.sh v0.13.7
run: bash /opt/gh-aw/actions/install_awf_binary.sh v0.13.12
Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

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

PR description focuses on the integration test change, but this file also bumps AWF/runtime image versions (v0.13.7 -> v0.13.12). Please call out these workflow lock updates explicitly in the PR description (or split into a separate PR) so reviewers understand the full scope of the change.

Copilot uses AI. Check for mistakes.
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.

2 participants