You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/07-cicd-publishing.md
+69-4Lines changed: 69 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -80,6 +80,38 @@ brew install edgeparse
80
80
81
81
---
82
82
83
+
## ⚠️ What's Missing / Must Be Configured Before Next Release
84
+
85
+
| Item | Status | Action Required |
86
+
|------|--------|----------------|
87
+
|**npm — Classic Automation Token**| ❌ Not done | Current `NPM_TOKEN` is a Granular token scoped only to `edgeparse`. Replace with a **Classic Automation token** so all 6 npm packages can publish. See [npm E403 troubleshooting](#npm-e403-forbidden-on-platform-packages-but-main-package-succeeds). |
88
+
|**PyPI — OIDC Trusted Publisher**| ❌ Not done |`release-python.yml` uses OIDC. The Trusted Publisher entry must be added at [pypi.org/manage/account/publishing](https://pypi.org/manage/account/publishing/) before CI can publish. See [PyPI OIDC troubleshooting](#pypi-oidc-invalid-publisher--token-request-failed). |
89
+
|**npm platform packages — manual publish for v0.2.0**| ⚠️ Workaround needed | Because the token is wrong, the 5 platform packages are NOT on npm at 0.2.0. Either fix the token and re-run the workflow, or publish them manually (see below). |
90
+
|**PyPI wheels — manual publish for v0.2.0**| ⚠️ Workaround needed | OIDC not configured. Publish manually with `PYPI_PASSWORD=<api-token> make publish-python` or from the downloaded wheel artifacts. |
91
+
92
+
### Manual npm publish for v0.2.0 (temporary workaround)
93
+
94
+
```bash
95
+
# 1. Get a Classic Automation token from npmjs.com
@@ -192,13 +224,14 @@ The npm package is `edgeparse` (unscoped). Platform-specific packages (`edgepars
192
224
**Steps (one-time):**
193
225
194
226
1. Sign in to [npmjs.com](https://www.npmjs.com) as the publisher account.
195
-
2. Go to **Account → Access Tokens → Generate New Token → Granular Access Token**.
227
+
2. Go to **Account → Access Tokens → Generate New Token → Classic Token**.
228
+
- Token type: **Automation** (bypasses 2FA prompts in CI)
196
229
- Token name: `edgeparse-github-actions`
197
-
- Expiration: 365 days (set a calendar reminder to rotate!)
198
-
- Packages and scopes: **Read and write** — all packages belonging to this account
199
230
3. Copy the token.
200
231
4. Add to GitHub: secret name `NPM_TOKEN`.
201
232
233
+
> **⚠️ IMPORTANT — Classic token, not Granular token:** A Granular Access Token only grants access to packages you explicitly list at creation time. Publishing 6 packages (`edgeparse` + 5 platform packages) requires either a **Classic Automation token** (access to all packages you own) or a Granular token with all 6 packages listed individually. If you see `E403 Forbidden` on platform packages but the main `edgeparse` publishes fine, your token was created as Granular with only `edgeparse` in scope — recreate it as a Classic Automation token.
234
+
202
235
> **Token rotation:** npm Granular Access Tokens expire. Rotate before expiry at [npmjs.com → Access Tokens](https://www.npmjs.com/settings/~/tokens).
The `NPM_TOKEN` secret is expired or invalid. Generate a new Granular Access Token at [npmjs.com/settings/~/tokens](https://www.npmjs.com/settings/~/tokens) and update the GitHub secret.
447
+
The `NPM_TOKEN` secret is expired or invalid. Generate a new Classic Automation token at [npmjs.com/settings/~/tokens](https://www.npmjs.com/settings/~/tokens) and update the GitHub secret.
448
+
449
+
### npm: E403 Forbidden on platform packages (but main package succeeds)
450
+
451
+
**Symptom:**`edgeparse@0.2.0` publishes successfully but all 5 platform packages (`edgeparse-darwin-arm64`, `edgeparse-darwin-x64`, etc.) fail with:
452
+
```
453
+
npm error 403 Forbidden - PUT https://registry.npmjs.org/edgeparse-darwin-arm64
454
+
- You may not perform that action with these credentials.
455
+
```
456
+
457
+
**Root cause:** The `NPM_TOKEN` is a **Granular Access Token** scoped to only the `edgeparse` package. Platform packages are not in scope.
458
+
459
+
**Fix — replace with a Classic Automation Token:**
460
+
461
+
1. Go to [npmjs.com → Account → Access Tokens](https://www.npmjs.com/settings/~/tokens).
462
+
2. Delete or retire the current granular token.
463
+
3. Click **Generate New Token → Classic Token** → type **Automation**.
464
+
4. Copy the token (shown only once).
465
+
5. Go to **GitHub repo → Settings → Secrets and variables → Actions → `NPM_TOKEN` → Update secret**.
466
+
6. Re-run the Node.js workflow:
467
+
```bash
468
+
gh workflow run release-node.yml --field tag_name=v0.2.0
469
+
```
470
+
471
+
> Platform packages that have NEVER been published (`edgeparse-darwin-x64`, `edgeparse-linux-x64-gnu`, etc.) also get E403 with a Granular token because — for packages that don't exist yet — npm still validates scope before creating them.
472
+
473
+
**Verify your token locally before updating the secret:**
0 commit comments