octokit.js: [MAINT]: NPM releases failing due to OTP token (2FA) requirements
Moving the discussion from https://github.com/octokit/openapi/issues/483#issuecomment-2714544040
The release workflow is failing because the token suddenly needs a one-time passcode (2FA).
https://github.com/octokit/openapi/actions/runs/13790432706/job/38568599440
npm error code EOTP
npm error This operation requires a one-time password from your authenticator.
npm error You can provide a one-time password by passing --otp=<code> to the command you ran.
npm error If you already provided a one-time password then it is likely that you either typoed
npm error it, or it timed out. Please try again.
npm error A complete log of this run can be found in: /home/runner/.npm/_logs/2025-03-11T14_28_01_144Z-debug-0.log
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Reactions: 2
- Comments: 15 (15 by maintainers)
okay we figured it out, the 2FA setting was enabled for both authorization and publishing. @nickfloyd changed it to just authorization, and the release now worked via https://github.com/octokit/openapi/actions/runs/13917749582/job/38991546989
https://github.com/octokit/openapi/releases/tag/v18.1.0
I’ll have a look today, I think that should be a straightforward fix
Ah I’m sorry I mixed up OTP with provenance attestation 🤦🏼 it was pre-coffee ☕
So it seems that the
@octokitorg on npm now enforces one-time passwords for publishing, which breaks our automated release workflow. I don’t know when that happened or why. I’ll try to find out but @nickfloyd might know more