Draft
Automate merge+regenerate flow for dependency PR generated files#4804
Conversation
Co-authored-by: xiang17 <9310587+xiang17@users.noreply.github.com>
Co-authored-by: xiang17 <9310587+xiang17@users.noreply.github.com>
Co-authored-by: xiang17 <9310587+xiang17@users.noreply.github.com>
Co-authored-by: xiang17 <9310587+xiang17@users.noreply.github.com>
Co-authored-by: xiang17 <9310587+xiang17@users.noreply.github.com>
Co-authored-by: xiang17 <9310587+xiang17@users.noreply.github.com>
Co-authored-by: xiang17 <9310587+xiang17@users.noreply.github.com>
Co-authored-by: xiang17 <9310587+xiang17@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Generate lockfiles and license report
Automate merge+regenerate flow for dependency PR generated files
Jul 31, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Dependency PRs were repeatedly conflicting on generated artifacts (
**/gradle.lockfile,licenses/more-licenses.md), creating an O(N²) resolve/re-run/re-approve loop. This PR makes regeneration deterministic and automated aftermainmoves, while preserving human intervention for real source conflicts.Reusable merge-and-regenerate workflow
.github/workflows/reusable-regenerate-generated-files.yml(workflow_call) as the single implementation of:origin/maininto PR head./gradlew resolveAndLockAll --write-locks./gradlew generateLicenseReport --no-build-cachemicrosoft/ApplicationInsights-JavamainMain fan-out + on-demand orchestration
.github/workflows/regenerate-generated-files.yml:pushtomain,issue_comment(/regenon PR),workflow_dispatch(pr_numberoptional)push: enumerates open dependency PRs withgh pr list ... --label dependencies, fans out with matrix (fail-fast: false,max-parallel: 3)regen-${{ matrix.pr }}with cancel-in-progress.github/workflows/regenerate-generated-files-runner.ymlfor single-PR dispatch execution path.Refactor existing helper to avoid logic duplication
.github/workflows/pull-request-helper.ymlto call the reusable workflow, keeping Dependabot-opened-PR behavior while sharing the same regeneration core.Permissions and action pinning
PR_HELPER_GITHUB_TOKEN) so regenerated pushes retrigger CI.gradle/actions/setup-gradlewithcache-read-only: true.Docs update
CONTRIBUTING.mdto document:mainregeneration behavior/regencommand usage