n4bb12 / verdaccio-github-oauth-ui

📦🔐 GitHub OAuth plugin for Verdaccio
https://verdaccio.org
MIT License
71 stars 45 forks source link

always-auth no longer available #170

Closed dataviruset closed 1 year ago

dataviruset commented 1 year ago

Bug Report

Versions

Software Version
This plugin v5.0.3
Node v19.4.0
NPM 9.2.0

Environment

Type Name Version
Package manager Homebrew 3.6.18
Browser Firefox 108.0.2
Operating system macOS Ventura 13.1

Observed behavior

After running npx verdaccio-github-oauth-ui, in the browser window that opens, it cannot write to the .npmrc file because of this error:

Command failed: npm config set //npm.redacted.com/:always-auth true npm ERR! `always-auth` is not a valid npm option npm ERR! A complete log of this run can be found in: npm ERR! /Users/oskar/.npm/_logs/2023-01-16T14_56_06_386Z-debug-0.log 

It seems always-auth has been obsolete from NPM v7 and forward, at least in the documentation. Here's a link to the documentation for v6. However, I tried with NPM v8 and it still works, so likely it has been removed in v9.

Expected behavior

That the authentication would succeed without error messages.

Maybe always-auth needs to be disabled if verdaccio-github-oauth-ui is running with a later NPM version, or if there's a replacement, couldn't find anything though, so it might have just been removed.

n4bb12 commented 1 year ago

Thanks for bringing this up. I think we can safely remove this option then. I'll do a major release to mark it as a breaking change in case someone is using npm 6 or older.

n4bb12 commented 1 year ago

🔗 https://github.com/n4bb12/verdaccio-github-oauth-ui/releases/tag/6.0.0