ci: align workflow push/pull_request triggers with shared structure#262
Open
Shreyas-Microsoft wants to merge 2 commits into
Open
ci: align workflow push/pull_request triggers with shared structure#262Shreyas-Microsoft wants to merge 2 commits into
Shreyas-Microsoft wants to merge 2 commits into
Conversation
Aligns the on: blocks across CI/CD workflows to match the structure used
by the Multi-Agent Custom Automation Engine Solution Accelerator
docker-build-and-push.yml reference workflow:
on:
push:
branches: [main, dev, demo, hotfix]
paths: [...]
pull_request:
types: [opened, ready_for_review, reopened, synchronize]
branches: [main, dev, demo, hotfix]
paths: [...]
Workflows updated:
- ci.yml: PR branches widened from [dev] to [main, dev, demo, hotfix];
push branches extended with hotfix; PR types added.
- deploy-v2.yml: PR branches widened from [dev] to [main, dev, demo,
hotfix]; push branches extended with hotfix; PR types added.
- test.yml: push and PR branches extended with demo and hotfix.
- pylint.yml: branches filter added to push (was running on every push);
full pull_request block added so linting also runs on PRs.
- validate-bicep-params.yml: PR branches extended with demo and hotfix;
PR types added.
docker-build-and-push.yml already followed the pattern and was left
untouched. Workflows that intentionally use only pull_request_target,
schedule, or workflow_dispatch (pr-title-checker, stale-bot,
broken-links-checker, etc.) were left untouched.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Aligns CI/CD workflow trigger contracts on the demo branch to a shared structure so workflows reliably run for push and pull_request events across main/dev/demo/hotfix, including explicit PR event types (e.g., ready_for_review).
Changes:
- Expanded
push.branchesfilters to includedemoandhotfixwhere missing. - Standardized
pull_requesttriggers to include explicittypes: [opened, ready_for_review, reopened, synchronize]and a consistent base-branch allowlist. - Preserved existing
pathsfilters while widening the triggering surface to the intended branches.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| .github/workflows/ci.yml | Adds hotfix for push and standardizes PR trigger (types + branches) to include main/dev/demo/hotfix. |
| .github/workflows/deploy-v2.yml | Adds hotfix for push and standardizes PR trigger (types + branches) to include main/dev/demo/hotfix. |
| .github/workflows/test.yml | Expands push/PR branch filters to include demo and hotfix (PR types already present). |
| .github/workflows/pylint.yml | Adds explicit push branch filter and adds PR trigger with matching types, branches, and paths. |
| .github/workflows/validate-bicep-params.yml | Expands PR branch filters to include demo and hotfix and adds explicit PR types. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
44
to
+46
| run: | | ||
| echo "Running Pylint..." | ||
| python -m flake8 --config=.flake8 --verbose . No newline at end of file | ||
| python -m flake8 --config=.flake8 --verbose . |
Comment on lines
43
to
+46
| - name: Pylint | ||
| run: | | ||
| echo "Running Pylint..." | ||
| python -m flake8 --config=.flake8 --verbose . No newline at end of file | ||
| python -m flake8 --config=.flake8 --verbose . |
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.
Purpose
Aligns the
on:block (push+pull_request) of all CI/CD workflows ondemoto the shared shape used by the Multi-Agent Custom Automation Engine Solution Acceleratordocker-build-and-push.ymlreference:Fixes the underlying issue that several workflows were not triggering on push / PR to
demo(orhotfix) because theirbranches:lists were limited to[main, dev]or[dev], and severalpull_requesttriggers were missing the explicittypes:block (so e.g.ready_for_reviewdid not start them).Each workflows existing
paths:filter is preserved verbatim (only the branches list, types list, and missing event were added) so the set of files that triggers each workflow is unchanged — only the set of branches it triggers on is widened.Workflows updated
ci.yml(Validate Deployment)[main, dev, demo], PR[dev], no PRtypes[main, dev, demo, hotfix], PR[main, dev, demo, hotfix]+typesdeploy-v2.yml(Deploy-Test-Cleanup v2)[main, dev, demo], PR[dev], no PRtypes[main, dev, demo, hotfix], PR[main, dev, demo, hotfix]+typestest.yml(Tests + Coverage)[main, dev][main, dev, demo, hotfix]pylint.yml(PyLint)branches:filter at all[main, dev, demo, hotfix]+ mirror PR block withtypes/branches/pathsvalidate-bicep-params.yml[main, dev], notypes[main, dev, demo, hotfix]+types(schedule + workflow_dispatch untouched)Workflows intentionally left untouched
docker-build-and-push.yml— already conforms to the reference structure (branches[main, dev, demo, hotfix], PRtypes, paths filter).pr-title-checker.yml— usespull_request_targetdeliberately (so it works on fork PRs); not apush/pull_requestworkflow.broken-links-checker.yml— intentionally runs on any PR that touches**/*.mdwith no branch filter (so doc-only PRs from any branch get checked); steps are gated onpull_request/workflow_dispatchand adding apushtrigger would just produce noisy no-op runs.azd-template-validation.yml,azure-dev.yml,Create-Release..yml,deploy-orchestrator.yml,job-*.yml,stale-bot.yml— have nopush:/pull_request:triggers at all (they are scheduled, manually-dispatched, or reusable callable workflows).Does this introduce a breaking change?
Golden Path Validation
Deployment Validation
What to Check
Verify that the following are valid
ci.yml,deploy-v2.yml,test.yml,pylint.yml,validate-bicep-params.yml) are still valid YAML and load cleanly (sanity-checked locally withyaml.safe_load).push:andpull_request:in each edited workflow is exactly[main, dev, demo, hotfix].pull_request:block hastypes: [opened, ready_for_review, reopened, synchronize].paths:filters are unchanged in each workflow (only widened by trigger surface, not by file set).demoactually starts the expected workflow runs — this is the main behavioural payoff of the PR.Other Information
demo(notmain) per the request, so the new triggers can be observed in pipeline runs without affectingmainfirst.mainafterwards so the trigger contracts stay consistent across branches.