[release/v7.5.7] Correct Variable Template Reference in NonOfficial Pipeline Templates#27462
Merged
adityapatwardhan merged 1 commit intoMay 18, 2026
Conversation
…PowerShell#27275) Co-authored-by: Justin Chung <[email protected]>
Contributor
There was a problem hiding this comment.
Pull request overview
Backport to release/v7.5.7 that fixes broken Azure DevOps YAML template references in NonOfficial pipelines by switching to repo-root-anchored template paths under /.pipelines/..., and updates the internal pipeline-splitting agent documentation to reflect .pipelines usage.
Changes:
- Update NonOfficial pipeline YAMLs to reference shared templates via
/.pipelines/templates/...@self(repo-root anchored), avoiding relative-path resolution issues. - Fix an in-template include in
PowerShell-vPack-Stages.ymlto use a root-anchored template reference. - Add
WindowsHostVersion.Version: 2022to the coordinated packages NonOfficial pipeline feature flags.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| .pipelines/templates/stages/PowerShell-vPack-Stages.yml | Fix template include path to be repo-root anchored (/.pipelines/...@self). |
| .pipelines/NonOfficial/PowerShell-vPack-NonOfficial.yml | Switch variable/stage template references to /.pipelines/...@self. |
| .pipelines/NonOfficial/PowerShell-Release-NonOfficial.yml | Switch variable/stage template references to /.pipelines/...@self. |
| .pipelines/NonOfficial/PowerShell-Release-Azure-NonOfficial.yml | Switch variables template reference to /.pipelines/...@self. |
| .pipelines/NonOfficial/PowerShell-Packages-NonOfficial.yml | Switch variable/stage template references to /.pipelines/...@self. |
| .pipelines/NonOfficial/PowerShell-Coordinated_Packages-NonOfficial.yml | Switch template references to /.pipelines/...@self and set Windows host version to 2022. |
| .github/agents/SplitADOPipelines.agent.md | Update .pipelines references and document a template include convention. |
Comment on lines
+28
to
+40
| ## Template Reference Convention (MUST follow) | ||
| All `- template:` references to files **inside this repo** must use the **absolute** form anchored at the repo root, with the `@self` suffix: | ||
|
|
||
| ```yaml | ||
| - template: /.pipelines/templates/<path>/<file>.yml@self | ||
| ``` | ||
|
|
||
| Do **not** use relative paths such as `templates/...`, `../templates/...`, or bare filenames. Rationale: | ||
|
|
||
| - Absolute paths resolve identically regardless of where the referring file lives, so moving a pipeline file between directories (for example, into `.pipelines/NonOfficial/`) does not silently break includes. | ||
| - Relative paths are resolved by Azure DevOps against the directory of the referring file, which has caused real outages in this repo when a relative include was composed into a nonexistent nested path like `.pipelines/templates/stages/.pipelines/templates/...`. | ||
| - The majority of existing includes already use the absolute form; keeping new work consistent reduces review burden. |
Comment on lines
61
to
65
| LinuxHostVersion: | ||
| Network: KS3 | ||
| WindowsHostVersion: | ||
| Version: 2022 | ||
| Network: KS3 |
SeeminglyScience
approved these changes
May 18, 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.
Backport of #27275 to release/v7.5.7
Triggered by @adityapatwardhan on behalf of @jshigetomi
Original CL Label: CL-BuildPackaging
/cc @PowerShell/powershell-maintainers
Impact
REQUIRED: Choose either Tooling Impact or Customer Impact (or both). At least one checkbox must be selected.
Tooling Impact
Standardizes .pipelines directory usage and corrects template import paths in NonOfficial pipeline YAML files, ensuring pipelines run as intended.
Customer Impact
Regression
REQUIRED: Check exactly one box.
This is not a regression.
Testing
Cherry-pick applied cleanly onto release/v7.5.7 with no conflicts. Verified branch commit and push succeeded. The change scope is limited to documentation and pipeline YAML path corrections.
Risk
REQUIRED: Check exactly one box.
Change is limited to documentation and pipeline configuration. No impact on runtime or customer-facing code. Ensures pipelines are functional and consistent.