Commit 74c633a
fix(release): apply PSR v10.5.3 bug mitigations to reusable workflow (#184)
PSR v10.5.3 has two bugs affecting the no-PyPI release pattern:
1. 422 on GitHub Release creation: github3 library serializes draft/prerelease
as JSON strings rather than booleans. Fix: vcs_release: "false" + separate
gh release create step that types booleans correctly.
2. Detached HEAD prevents branch matching: actions/checkout with ref: <sha>
leaves HEAD detached; PSR needs an attached branch to match branches config.
Fix: git checkout -B "$HEAD_BRANCH" after checkout.
Also adds:
- Fork verification step for workflow_run callers (S7631)
- SHA-pinned checkout (ref: workflow_run.head_sha || github.sha)
- commit: "false" so PSR only pushes tags (branch rulesets exempt tag refs)
- publish-to-pypi default changed from true to false
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent e75a86b commit 74c633a
1 file changed
Lines changed: 41 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
66 | 66 | | |
67 | 67 | | |
68 | 68 | | |
69 | | - | |
| 69 | + | |
70 | 70 | | |
71 | 71 | | |
72 | 72 | | |
| |||
249 | 249 | | |
250 | 250 | | |
251 | 251 | | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
252 | 263 | | |
253 | 264 | | |
254 | 265 | | |
| |||
266 | 277 | | |
267 | 278 | | |
268 | 279 | | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
269 | 290 | | |
270 | 291 | | |
271 | 292 | | |
| |||
347 | 368 | | |
348 | 369 | | |
349 | 370 | | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
350 | 380 | | |
351 | 381 | | |
352 | 382 | | |
| |||
355 | 385 | | |
356 | 386 | | |
357 | 387 | | |
358 | | - | |
| 388 | + | |
359 | 389 | | |
360 | | - | |
361 | | - | |
362 | | - | |
363 | | - | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
364 | 399 | | |
365 | 400 | | |
366 | 401 | | |
| |||
0 commit comments