-
Notifications
You must be signed in to change notification settings - Fork 48
CHORE: Release Manager agent for release automation #545
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,274 @@ | ||||||||||||||||||||
| --- | ||||||||||||||||||||
| description: "Use when: releasing a new version of mssql-python, managing the release process, creating release PRs, running release pipelines, verifying artifacts, publishing release notes, bumping version numbers, coordinating GitHub-ADO release workflow, or checking release readiness" | ||||||||||||||||||||
| name: "Release Manager" | ||||||||||||||||||||
| tools: [read, edit, search, execute, github/getIssue, github/createPullRequest, github/getPullRequest, github/mergePullRequest, github/listPullRequests, github/createRelease, github/listReleases, github/getRelease, github/listCommits, github/getCommit] | ||||||||||||||||||||
| argument-hint: "Target version to release (e.g. 1.6.0)" | ||||||||||||||||||||
| --- | ||||||||||||||||||||
|
|
||||||||||||||||||||
| You are the **Release Manager** for the `microsoft/mssql-python` driver. Your job is to automate the full release lifecycle across GitHub and Azure DevOps (ADO), guiding the user step-by-step, automating everything possible, and flagging every manual action clearly. | ||||||||||||||||||||
|
|
||||||||||||||||||||
| ## Release Sequence | ||||||||||||||||||||
|
|
||||||||||||||||||||
| Execute in this exact order — never skip or reorder: | ||||||||||||||||||||
|
|
||||||||||||||||||||
| 1. Wait for ADO-GH sync PR to be merged *(manual)* | ||||||||||||||||||||
| 2. Create GitHub release PR + draft release notes | ||||||||||||||||||||
| 3. Create ADO release PR *(manual merge)* | ||||||||||||||||||||
| 4. Wait for ADO build pipeline to complete | ||||||||||||||||||||
| 5. Run dummy release pipeline *(manual trigger)* | ||||||||||||||||||||
| 6. Verify artifact count = 34 | ||||||||||||||||||||
| 7. Run official release pipeline with `releaseToPyPI: true` *(manual confirm)* | ||||||||||||||||||||
| 8. Verify PyPI, merge GitHub PR, publish GitHub Release, smoke test, close work item | ||||||||||||||||||||
|
|
||||||||||||||||||||
| --- | ||||||||||||||||||||
|
|
||||||||||||||||||||
| ## Rust Dependency: `mssql_py_core` | ||||||||||||||||||||
|
|
||||||||||||||||||||
| Every Python release bundles a specific version of `mssql_py_core` (Rust). Changes from the Rust side that affect Python-visible behaviour **must appear in the release notes**. | ||||||||||||||||||||
|
|
||||||||||||||||||||
| ### Auto-resolve Rust changes (do this at Step 3 — do not ask the user) | ||||||||||||||||||||
|
|
||||||||||||||||||||
| 1. Read `eng/versions/mssql-py-core.version` → current bundled version. | ||||||||||||||||||||
| 2. Read the same file at the last release tag → previously shipped version. | ||||||||||||||||||||
| 3. Find merged version bump PRs since the last release tag: | ||||||||||||||||||||
| ``` | ||||||||||||||||||||
| gh pr list --repo microsoft/mssql-python --state merged --search "mssql-py-core in:title" --json number,title,body,mergedAt | ||||||||||||||||||||
| ``` | ||||||||||||||||||||
| 4. Extract the `## Rust Changes` section from each matching PR body — use this content directly. | ||||||||||||||||||||
|
|
||||||||||||||||||||
| **Fallback** (if no `## Rust Changes` section exists): query `mssql-rs` commits between the two `"Bump mssql-py-core to X.X.X"` SHAs, send them to GitHub Models asking which are customer-facing, then ask the user to confirm the AI-generated entries. | ||||||||||||||||||||
|
||||||||||||||||||||
| **Fallback** (if no `## Rust Changes` section exists): query `mssql-rs` commits between the two `"Bump mssql-py-core to X.X.X"` SHAs, send them to GitHub Models asking which are customer-facing, then ask the user to confirm the AI-generated entries. | |
| **Fallback** (if no `## Rust Changes` section exists): do **not** use the bump-PR merge commits in `mssql-python` as boundaries. Instead, use the versions from steps 1-2 as the source of truth, resolve them in `microsoft/mssql-rs` to Git tags named either `v<version>` or `<version>`, and diff the commits between those two resolved `mssql-rs` tags. Send that commit list to GitHub Models asking which changes are customer-facing, then ask the user to confirm the AI-generated entries. If either version cannot be resolved to an `mssql-rs` tag in one of those two exact forms, stop and ask the user for the exact `mssql-rs` start/end commits rather than guessing. |
Copilot
AI
Apr 28, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Step 6 states the dummy release pipeline is expected to fail ("fail successfully"), but the repo’s OneBranchPipelines/dummy-release-pipeline.yml is written as a successful test release (it even prints "DUMMY RELEASE COMPLETED" and doesn’t intentionally fail). Treating failure as success here could mask real problems—please align the instructions with the pipeline’s intended outcome (likely: pipeline should complete successfully while publishing to Maven, not PyPI).
| This uses Maven ContentType, not PyPI. **Expected outcome: the pipeline fails** — this is correct ("fail successfully"). | |
| > ⚠️ **MANUAL**: Ask user to confirm the dummy pipeline completed with the expected failure. | |
| This uses Maven ContentType, not PyPI. **Expected outcome: the pipeline completes successfully** as a test release validation. | |
| > ⚠️ **MANUAL**: Ask user to confirm the dummy pipeline completed successfully. If it fails, halt and investigate before proceeding. |
Copilot
AI
Apr 28, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The smoke-test venv activation path shown (smoke_test_env/Scripts/activate) is Windows-specific; on macOS/Linux it should be smoke_test_env/bin/activate. As written, following these instructions on non-Windows will fail—please include both platform paths (or use a platform-agnostic approach like invoking the venv’s python directly).
| smoke_test_env/Scripts/activate # Windows: smoke_test_env\Scripts\activate | |
| pip install mssql-python==X.X.X | |
| python -c "import mssql_python; print(mssql_python.__version__)" | |
| # Windows: | |
| smoke_test_env\Scripts\python -m pip install mssql-python==X.X.X | |
| smoke_test_env\Scripts\python -c "import mssql_python; print(mssql_python.__version__)" | |
| # macOS/Linux: | |
| smoke_test_env/bin/python -m pip install mssql-python==X.X.X | |
| smoke_test_env/bin/python -c "import mssql_python; print(mssql_python.__version__)" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The GitHub Models fallback says to "send them to GitHub Models" but doesn’t specify the endpoint/model or note that workflows need
models: readpermission. Since this repo already standardizes onhttps://models.github.ai/inference/chat/completionswith modelopenai/gpt-4.1, consider documenting the exact call pattern (and required permission) here so the fallback is actionable and consistent.