Repository navigation
Commit 24b7cd1
authored
ci: migrate release-please to upstream action (#3568)
## Summary
- replace `stainless-api/trigger-release-please` with the upstream
`googleapis/release-please-action`, pinned to verified v5.0.0 commit
`45996ed`
- run release-please explicitly against `main` with the repository's
manifest configuration
- use the built-in `GITHUB_TOKEN` explicitly and remove the
`STAINLESS_API_KEY` action input
- switch the config schema to upstream release-please and remove
Stainless's prerelease/beta settings
- explicitly dispatch required checks for the generated
`release-please--branches--main` PR
- keep the `publish` environment scoped to the PyPI publish job
## Impact
Release PRs and GitHub releases are now managed entirely by the
open-source release-please action. Stable release versions continue to
update `CHANGELOG.md`, `.release-please-manifest.json`,
`pyproject.toml`, and `src/openai/_version.py`; successful GitHub
release creation still gates the existing build and trusted PyPI publish
jobs.
Release Please deliberately uses `GITHUB_TOKEN`. Because GitHub
suppresses ordinary push and pull-request events created by that token,
a separate least-privilege job explicitly dispatches CI, breaking-change
detection, and CodeQL against the generated release PR. It fetches the
PR's live base SHA immediately before dispatch and restricts this path
to the exact `release-please--branches--main` ref.
## Permission audit
- release: `contents: write` for the release branch, tags, and GitHub
releases; `pull-requests: write` for release PRs; `issues: write` for PR
labels
- release PR checks: `actions: write` only to dispatch workflows and
`pull-requests: read` only to obtain the current base SHA and verify the
generated head branch
- CI and breaking-change workflows: default `contents: read`; the
secret-bearing examples job is not dispatched for release PRs
- CI build: `contents: read` only, with checkout credential persistence
disabled; the Stainless mirror's OIDC upload is isolated in a separate
Stainless-only job
- CodeQL: `contents: read` and `security-events: write` in its existing
dedicated workflow
- package build: `contents: read` only, with checkout credential
persistence disabled
- publish: `id-token: write` only for PyPI Trusted Publishing
- no App private key, Stainless credential, or PyPI credential is
exposed to the release workflow
## Validation
- release-please v17.6.0 `debug-config --dry-run`: loaded the Python
strategy with stable/default versioning and target branch `main`
- release-please v17.6.0 `release-pr --dry-run`: generated the expected
stable branch and version-file changes
- release-please config validated against the exact v17.6.0 upstream
JSON schema; current manifest baseline is `2.52.1`
- pinned action interface, outputs, branch naming, and documented
permissions verified against upstream source
- actionlint and YAML/JSON parsing
- `git diff --check`
- thermo-nuclear code-quality review: no findings
## Cutover prerequisites completed
- existing Stainless release PR #3562 was reviewed, merged, and released
successfully as
[v2.52.1](https://github.com/openai/openai-python/releases/tag/v2.52.1);
the current release workflow completed GitHub release creation, build,
and PyPI publishing in [run
30835897995](https://github.com/openai/openai-python/actions/runs/30835897995)
- GitHub rejected its built-in Actions integration as a ruleset bypass
actor, so active legacy ruleset `15951502` now excludes only
`refs/heads/release-please--branches--main`; all other
`release-please--*` branches and the two original bypass actors remain
unchanged
- the migration branch includes the published `2.52.1` manifest/version
baseline
## After merge
- remove the now-unused `STAINLESS_API_KEY` secret from the
repository/environment
- any future migration to the `openai-sdks` App should be handled
separately; this PR intentionally uses only `GITHUB_TOKEN`1 parent f83b1f4 commit 24b7cd1
4 files changed
Lines changed: 158 additions & 26 deletions
File tree
- .github/workflows
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
17 | 23 | | |
18 | 24 | | |
19 | 25 | | |
20 | 26 | | |
21 | 27 | | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
22 | 31 | | |
23 | 32 | | |
24 | 33 | | |
25 | 34 | | |
26 | 35 | | |
27 | | - | |
| 36 | + | |
28 | 37 | | |
29 | 38 | | |
30 | 39 | | |
| |||
41 | 50 | | |
42 | 51 | | |
43 | 52 | | |
44 | | - | |
| 53 | + | |
45 | 54 | | |
46 | 55 | | |
47 | 56 | | |
48 | 57 | | |
49 | | - | |
50 | 58 | | |
51 | 59 | | |
52 | 60 | | |
| 61 | + | |
| 62 | + | |
53 | 63 | | |
54 | 64 | | |
55 | 65 | | |
| |||
88 | 98 | | |
89 | 99 | | |
90 | 100 | | |
91 | | - | |
| 101 | + | |
92 | 102 | | |
93 | 103 | | |
94 | 104 | | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
95 | 133 | | |
96 | 134 | | |
97 | 135 | | |
98 | 136 | | |
99 | 137 | | |
100 | 138 | | |
101 | | - | |
102 | | - | |
103 | | - | |
104 | 139 | | |
105 | 140 | | |
106 | 141 | | |
| |||
111 | 146 | | |
112 | 147 | | |
113 | 148 | | |
114 | | - | |
| 149 | + | |
115 | 150 | | |
116 | 151 | | |
117 | 152 | | |
| |||
147 | 182 | | |
148 | 183 | | |
149 | 184 | | |
150 | | - | |
| 185 | + | |
151 | 186 | | |
152 | 187 | | |
153 | 188 | | |
| |||
224 | 259 | | |
225 | 260 | | |
226 | 261 | | |
227 | | - | |
| 262 | + | |
228 | 263 | | |
229 | 264 | | |
230 | 265 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
13 | 12 | | |
14 | 13 | | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
15 | 17 | | |
16 | 18 | | |
| 19 | + | |
| 20 | + | |
17 | 21 | | |
18 | 22 | | |
19 | | - | |
20 | | - | |
21 | | - | |
| 23 | + | |
22 | 24 | | |
23 | 25 | | |
24 | | - | |
25 | | - | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
26 | 104 | | |
27 | 105 | | |
28 | 106 | | |
| |||
36 | 114 | | |
37 | 115 | | |
38 | 116 | | |
| 117 | + | |
| 118 | + | |
39 | 119 | | |
40 | 120 | | |
41 | 121 | | |
| |||
64 | 144 | | |
65 | 145 | | |
66 | 146 | | |
67 | | - | |
68 | 147 | | |
69 | 148 | | |
70 | 149 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
7 | 21 | | |
8 | 22 | | |
9 | 23 | | |
10 | 24 | | |
11 | 25 | | |
12 | | - | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
13 | 30 | | |
14 | 31 | | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
15 | 35 | | |
16 | | - | |
| 36 | + | |
17 | 37 | | |
18 | 38 | | |
19 | 39 | | |
| |||
30 | 50 | | |
31 | 51 | | |
32 | 52 | | |
33 | | - | |
| 53 | + | |
34 | 54 | | |
35 | 55 | | |
36 | 56 | | |
37 | 57 | | |
38 | | - | |
| 58 | + | |
39 | 59 | | |
40 | 60 | | |
41 | 61 | | |
42 | 62 | | |
43 | | - | |
| 63 | + | |
44 | 64 | | |
45 | 65 | | |
46 | 66 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
| 2 | + | |
2 | 3 | | |
3 | 4 | | |
4 | 5 | | |
5 | | - | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
9 | | - | |
10 | 8 | | |
11 | 9 | | |
12 | 10 | | |
| |||
63 | 61 | | |
64 | 62 | | |
65 | 63 | | |
66 | | - | |
| 64 | + | |
0 commit comments