Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 19, 2025

The update command now applies automatic codemods after updating workflows from their sources, ensuring workflows follow latest best practices without manual intervention.

Changes

  • Modified UpdateWorkflowsWithExtensionCheck: Added Step 4 to run RunFix after workflow updates but before PR creation
  • Error handling: Fix failures are non-fatal and logged as warnings in verbose mode only
  • Updated help text: Documents the new automatic fix step in the 5-step update process

Implementation

// Step 4: Apply automatic fixes to updated workflows
fixConfig := FixConfig{
    WorkflowIDs: workflowNames,
    Write:       true,
    Verbose:     verbose,
}
if err := RunFix(fixConfig); err != nil {
    updateLog.Printf("Fix command failed (non-fatal): %v", err)
    if verbose {
        fmt.Fprintln(os.Stderr, console.FormatWarningMessage(
            fmt.Sprintf("Warning: automatic fixes failed: %v", err)))
    }
}

When users run gh aw update, workflows are now automatically migrated to use current syntax (e.g., timeout_minutestimeout-minutes, network.firewallsandbox.agent).

Original prompt

Integrating running "fix" as part of the "update" command flow. See UpdateWorkflowsWithExtensionCheck


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 3 commits December 19, 2025 21:59
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
- Added RunFix call in UpdateWorkflowsWithExtensionCheck after updating workflows
- Fix is applied automatically after workflow updates but before PR creation
- Fix failures are logged but don't fail the update (non-fatal)
- Updated documentation in update command help text to mention step 5
- Added comprehensive tests for fix integration
- Verified fix works correctly on workflows with deprecated fields

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title [WIP] Integrate running fix in update command flow Integrate fix codemods into update command flow Dec 19, 2025
Copilot AI requested a review from pelikhan December 19, 2025 22:14
@pelikhan pelikhan marked this pull request as ready for review December 19, 2025 22:18
@pelikhan pelikhan merged commit b1cb3ae into main Dec 19, 2025
4 checks passed
@pelikhan pelikhan deleted the copilot/integrate-fix-in-update-flow branch December 19, 2025 23:26
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