Skip to content

Fix first-release CI path initialization - #50548

Merged
Xiaofei Cao (XiaofeiCao) merged 4 commits into
Azure:mainfrom
XiaofeiCao:fix-first-release-ci
Sep 23, 2026
Merged

Xiaofei Cao (XiaofeiCao) merged 4 commits into
Azure:mainfrom
XiaofeiCao:fix-first-release-ci

Conversation

@XiaofeiCao

@XiaofeiCao Xiaofei Cao (XiaofeiCao) commented Sep 22, 2026 •

Copy link
Copy Markdown
Member

Description

PR that fix issue in sdk repo: #50547

Update first-release SDK metadata automation so packages added to an existing service-level ci.yml also receive complete CI path filters.

  • Add the package directory to trigger.paths.include and pr.paths.include.
  • Add the package pom.xml to trigger.paths.exclude and pr.paths.exclude.
  • Keep the Python SDK-generation path and PowerShell inner-loop metadata path aligned.
  • Preserve existing filters, avoid duplicate entries on reruns, and reject malformed filter structures.

This prevents newly initialized SDK packages from requiring the manual ci.yml corrections made in #50547.

Verification

  • python eng\automation\test_generate.py — 18 passed
  • Pester eng\scripts\tests\Automation-Sdk-UpdateMetadata.tests.ps1 — 53 passed, 0 failed
  • git diff --check

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 2 pipeline(s).
33 pipeline(s) were filtered out due to trigger conditions.
There may be pipelines that require an authorized user to comment /azp run to run.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 3 pipeline(s).
32 pipeline(s) were filtered out due to trigger conditions.
There may be pipelines that require an authorized user to comment /azp run to run.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

The new CI path-filter logic will throw on valid ci.yml patterns like trigger: none / pr: none, and the RevApi suppression removal appears out-of-scope relative to the PR’s stated purpose.

Get a fresh assessment by requesting another Copilot review.

Review effort: Lite
Findings: 2 Medium severity · 1 Low severity

Open (3)
What changed in this PR

Updates the first-release metadata automation to ensure newly added packages get correct CI trigger/pr path filters when they’re added to an existing service-level ci.yml, aligning the Python implementation with the PowerShell inner-loop script and expanding automated coverage.

Changes:

  • Add CI path-filter update logic to both Python (update_ci_path_filters) and PowerShell (Update-CiPathFilters) and wire it into the existing ci.yml update flow.
  • Expand Pester + Python unit tests to validate idempotency, preservation of existing filters, and malformed filter rejection.
  • Remove two RevApi suppressions for azure-resourcemanager-network breaking changes (currently not mentioned in the PR description).
File Description
eng/​scripts/​tests/​Automation-Sdk-UpdateMetadata.tests.ps1 Adds Pester coverage for path filter updates and verifies Update-CiYml writes filters even when the artifact already exists.
eng/​scripts/​helpers/​Metadata-Helpers.ps1 Introduces Update-CiPathFilters and integrates it into Update-CiYml write conditions.
eng/​automation/​utils.py Adds update_ci_path_filters and ensures ci.yml is rewritten when only filters change.
eng/​automation/​test_generate.py Adds unit tests for update_ci_path_filters and the “artifact already exists but filters missing” scenario.
eng/​lintingconfigs/​revapi/​track2/​revapi.json Removes RevApi filters for two network model breaking changes (scope mismatch with PR description).

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

Comment thread eng/automation/utils.py Resolved
Comment thread eng/automation/utils.py Resolved
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Comment thread eng/automation/utils.py Resolved
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@XiaofeiCao

Copy link
Copy Markdown
Member Author

/azp run java - spring - ci

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
1 pipeline(s) were filtered out due to trigger conditions.

@XiaofeiCao
Xiaofei Cao (XiaofeiCao) merged commit 34d926d into Azure:main Sep 23, 2026
26 checks passed
browndav-msft pushed a commit to browndav-msft/azure-sdk-for-java that referenced this pull request Oct 14, 2026
* Fix first-release CI path initialization

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

* Remove released Network RevApi suppressions

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

* Support disabled CI triggers and omitted path filters

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

* Make CI path enrichment non-fatal

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
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.

3 participants