| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
@copilot It looks like you don't have access to push changes to .github/workflows. Can you make these changes again without updating the rebuild workflow? |
Sorry, something went wrong.
|
@copilot It looks like you don't have access to push changes to .github/workflows. Can you make these changes again without updating the rebuild workflow? |
Sorry, something went wrong.
|
@copilot It looks like you don't have access to push changes to .github/workflows. Can you make these changes again without updating the rebuild workflow? |
Sorry, something went wrong.
Co-authored-by: henrymercer <14129055+henrymercer@users.noreply.github.com>
I've recreated the sync-back automation without modifying the rebuild workflow as requested. The changes include:
The automation successfully synced the following action version updates:
All changes are now committed in 8d31b53. |
Sorry, something went wrong.
|
Sorry, something went wrong.
… preservation, and tests Co-authored-by: henrymercer <14129055+henrymercer@users.noreply.github.com>
I've addressed all the feedback points in commit f77ed60:
The automation now auto-detects 7 different actions in the current workflows and handles comment preservation correctly. |
Sorry, something went wrong.
|
@copilot That looks great, thanks! The script updates Action version references in regular workflow files, but Dependabout would update these for us. It's only the ones in sync.py and pr-checks that the sync back automation needs to update. Could you update the script to only update the necessary files? |
Sorry, something went wrong.
Co-authored-by: henrymercer <14129055+henrymercer@users.noreply.github.com>
Updated the script to only update the necessary files (sync.py and pr-checks templates). Removed the regular workflow file updates since Dependabot handles those automatically. The script now focuses only on syncing versions back to source templates where they're needed. Commit 5d79536. |
Sorry, something went wrong.
|
@copilot Great. Before, you didn't seem to have access to modify .github/workflows, but let's try again. Could you modify the Rebuild workflow to run the sync back script. We'll need to run it before we run the sync.py script otherwise that script will overwrite Dependabot's changes. |
Sorry, something went wrong.
Co-authored-by: henrymercer <14129055+henrymercer@users.noreply.github.com>
I've successfully modified the rebuild workflow to run the sync-back script before sync.py. The workflow now executes python3 sync-back.py followed by python3 sync.py in the "Generate workflows" step, ensuring that Dependabot's action version updates are synced back to source templates before the sync.py script regenerates the workflows. This prevents sync.py from overwriting Dependabot's changes. Commit f537110. |
Sorry, something went wrong.
There was a problem hiding this comment.
This PR enhances the CodeQL Action repository with comprehensive sync-back automation for Dependabot action version updates. The main purpose is to ensure that when Dependabot updates action versions in generated workflow files, those changes are automatically reflected in the source templates that generate them.
Key changes include:
Copilot reviewed 14 out of 15 changed files in this pull request and generated 3 comments.
Show a summary per file| File | Description |
|---|---|
| pr-checks/sync_back.py | New automation script that scans generated workflows and syncs action versions back to templates |
| pr-checks/test_sync_back.py | Comprehensive test suite for the sync-back functionality |
| pr-checks/sync.py | Updated hardcoded action versions for setup-node (v4→v5) and setup-go (v5→v6) |
| pr-checks/readme.md | Added documentation for sync-back automation usage and testing |
| pr-checks/.gitignore | Added Python cache file exclusions |
| .github/workflows/rebuild.yml | Integrated sync-back script execution before sync.py |
| .github/workflows/pr-checks.yml | Added test execution for pr-checks module |
| Template files in pr-checks/checks/ | Updated action versions (github-script v7→v8, setup-go v5→v6) to match current versions |
Sorry, something went wrong.
There was a problem hiding this comment.
Having a script to sync-back the version updates that Dependabot makes to the generated workflow files would be a nice QoL improvement for us.
I am not a huge fan of this particular work, although I won't object to merging it once we have decided what to do about my comments. I've added a bunch of comments about things in this that are subtly wrong or could easily break. Those can be fixed or ignored.
In the long run, I'd like to see us invest less in adding more Python scripts and associated infrastructure to the repo and implement new scripts in less ad-hoc and more maintainability way.
Sorry, something went wrong.
In favour of docs in the script itself
There was a problem hiding this comment.
I think you've addressed my main concerns here; just a few small follow-up comments.
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Bumps the actions group with 4 updates: actions/setup-go, actions/github-script, actions/setup-node and actions/setup-python.
Additionally, adds automation to sync Dependabot action version updates back to the source templates in the pr-checks directory and integrates it into the rebuild workflow.
Dependabot Updates
Updates actions/setup-go from 5 to 6
Updates actions/github-script from 7 to 8
Updates actions/setup-node from 4 to 5
Updates actions/setup-python from 5 to 6
Enhanced Sync-Back Automation
This PR adds a new Python script (pr-checks/sync-back.py) that automatically syncs Dependabot action version updates back to the source templates in the pr-checks directory. When Dependabot updates action versions in the generated workflows (.github/workflows/__*.yml), this script ensures those changes are properly reflected in:
The script does not update regular workflow files since Dependabot handles those automatically, focusing only on the source templates that require sync-back.
Key Features
The script automatically detects and handles multiple action types beyond the original 4, ensuring the verify-pr-checks.sh test always passes.
Workflow Integration
The sync-back script is now integrated into the rebuild workflow (.github/workflows/rebuild.yml) to run automatically before the sync.py script. This ensures that when the rebuild workflow is triggered, Dependabot's action version updates are first synced back to the source templates before the workflows are regenerated, preventing sync.py from overwriting Dependabot's changes.
Files Added/Modified
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.