Skip to content

Add agentic management SDK PR review workflow - #48511

Merged
Yuchao Yan (msyyc) merged 3 commits into
Azure:mainfrom
msyyc:mgmt-sdk-pr-review-agentic-workflow
Aug 10, 2026
Merged

Add agentic management SDK PR review workflow#48511
Yuchao Yan (msyyc) merged 3 commits into
Azure:mainfrom
msyyc:mgmt-sdk-pr-review-agentic-workflow

Conversation

@msyyc

@msyyc Yuchao Yan (msyyc) commented Aug 10, 2026

Copy link
Copy Markdown
Member

for #48444

Summary

  • add a label-triggered agentic workflow for Python management SDK PR reviews
  • apply the current MGMT SDK Code Review Rules from the repository default branch
  • deterministically compare _metadata.json API versions at the first and latest PR commits
  • post one self-updating advisory comment through safe outputs without checking out PR code

Validation

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

Copilot-Session: 7ab228dc-97fc-4bca-acb2-884fbda8c40c
@azure-pipelines

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

@msyyc
Yuchao Yan (msyyc) marked this pull request as ready for review August 10, 2026 06:41
@msyyc
Yuchao Yan (msyyc) requested a review from a team as a code owner August 10, 2026 06:41
Copilot AI balanced review requested due to automatic review settings August 10, 2026 06:41
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).
10 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>

Copilot-Session: 7ab228dc-97fc-4bca-acb2-884fbda8c40c
@msyyc
Yuchao Yan (msyyc) marked this pull request as draft August 10, 2026 06:42
@msyyc
Yuchao Yan (msyyc) marked this pull request as ready for review August 10, 2026 06:43
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).
10 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.

Pull request overview

Adds a label-triggered agentic workflow for management SDK PR reviews.

Changes:

  • Collects management-package and API-version context.
  • Applies current default-branch review rules.
  • Generates the executable workflow lock file.

Reviewed changes

Copilot reviewed 1 out of 2 changed files in this pull request and generated 2 comments.

File Description
.github/workflows/mgmt-sdk-pr-review.md Defines review logic and agent instructions.
.github/workflows/mgmt-sdk-pr-review.lock.yml Compiled GitHub Actions workflow.

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

Comment thread .github/workflows/mgmt-sdk-pr-review.md Outdated
Comment thread .github/workflows/mgmt-sdk-pr-review.md
Copilot AI review requested due to automatic review settings August 10, 2026 06:45

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.

Pull request overview

Copilot reviewed 1 out of 2 changed files in this pull request and generated no new comments.

Suppressed comments (2)

.github/workflows/mgmt-sdk-pr-review.md:167

  • /pulls/{number}/commits returns at most 250 commits, so on a larger PR this value is the 250th commit rather than the actual latest commit. The drift check and all subsequent review evidence would therefore be evaluated against stale state. Read the current PR's validated head.sha for latest_revision while retaining the commit list only to obtain the first revision, then regenerate the lock file.
      latest_revision = commit_shas[-1]

.github/workflows/mgmt-sdk-pr-review.md:157

  • Renamed files are matched only by their new filename. GitHub exposes the old path as previous_filename, so renaming a management package to a path that no longer matches this pattern makes affectedPackages empty and the workflow incorrectly reports that the review is not applicable. Collect matches from both fields (and retain the previous path in changedFiles), then regenerate the lock file.
              for item in changed_files
              if isinstance(item.get("filename"), str)
              for match in [PACKAGE_PATTERN.match(item["filename"])]
              if match

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

Copilot-Session: 7ab228dc-97fc-4bca-acb2-884fbda8c40c
Copilot AI review requested due to automatic review settings August 10, 2026 07:00

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.

Pull request overview

Copilot reviewed 1 out of 2 changed files in this pull request and generated no new comments.

@msyyc
Yuchao Yan (msyyc) merged commit 5267939 into Azure:main Aug 10, 2026
17 checks passed
@msyyc
Yuchao Yan (msyyc) deleted the mgmt-sdk-pr-review-agentic-workflow branch August 10, 2026 07:33
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