-
Notifications
You must be signed in to change notification settings - Fork 5.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(npm): use configured auth for tarball urls instead of scope auth (#…
…24111) Deno was using the scope auth for the tarball urls, which is not always correct. We are going to do a release immediately for this issue.
- Loading branch information
Showing
35 changed files
with
194 additions
and
61 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
tests/registry/npm-private/@denotest/tarballs-privateserver2/1.0.0/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
module.exports = () => 'hi_private1'; |
4 changes: 4 additions & 0 deletions
4
tests/registry/npm-private/@denotest/tarballs-privateserver2/1.0.0/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"name": "@denotest/tarballs-privateserver2", | ||
"version": "1.0.0" | ||
} |
1 change: 1 addition & 0 deletions
1
tests/registry/npm-private2/@denotest/tarballs-privateserver2/1.0.0/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
module.exports = () => 'hi_private2'; |
4 changes: 4 additions & 0 deletions
4
tests/registry/npm-private2/@denotest/tarballs-privateserver2/1.0.0/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"name": "@denotest/tarballs-privateserver2", | ||
"version": "1.0.0" | ||
} |
2 changes: 2 additions & 0 deletions
2
tests/registry/npm/@denotest/tarballs-privateserver2/1.0.0/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
// this is a special package that the test server serves tarballs from the second private registry server | ||
module.exports = () => 'hi'; |
4 changes: 4 additions & 0 deletions
4
tests/registry/npm/@denotest/tarballs-privateserver2/1.0.0/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"name": "@denotest/tarballs-privateserver2", | ||
"version": "1.0.0" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
@denotest:registry=http://127.0.0.1:4261/ | ||
//127.0.0.1:4261/:_authToken=private-reg-token | ||
@denotest2:registry=http://127.0.0.1:4262/ | ||
//127.0.0.1:4262/:_authToken=private-reg-token2 | ||
@denotest:registry=http://localhost:4261/ | ||
//localhost:4261/:_authToken=private-reg-token | ||
@denotest2:registry=http://localhost:4262/ | ||
//localhost:4262/:_authToken=private-reg-token2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
⚠️ `deno install` behavior will change in Deno 2. To preserve the current behavior use the `-g` or `--global` flag. | ||
[UNORDERED_START] | ||
Download http://127.0.0.1:4261/@denotest/basic | ||
Download http://127.0.0.1:4262/@denotest2/basic | ||
Download http://localhost:4261/@denotest/basic | ||
Download http://localhost:4262/@denotest2/basic | ||
Download http://localhost:4261/@denotest/basic/1.0.0.tgz | ||
Download http://localhost:4262/@denotest2/basic/1.0.0.tgz | ||
Initialize @denotest2/[email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
@denotest:registry=http://127.0.0.1:4261/ | ||
//127.0.0.1:4261/:_authToken=private-reg-token | ||
@denotest2:registry=http://127.0.0.1:4262/ | ||
//127.0.0.1:4262/:_authToken=private-reg-token2 | ||
@denotest:registry=http://localhost:4261/ | ||
//localhost:4261/:_authToken=private-reg-token | ||
@denotest2:registry=http://localhost:4262/ | ||
//localhost:4262/:_authToken=private-reg-token2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
⚠️ `deno install` behavior will change in Deno 2. To preserve the current behavior use the `-g` or `--global` flag. | ||
[UNORDERED_START] | ||
Download http://127.0.0.1:4261/@denotest/basic | ||
Download http://127.0.0.1:4262/@denotest2/basic | ||
Download http://localhost:4261/@denotest/basic | ||
Download http://localhost:4262/@denotest2/basic | ||
Download http://localhost:4261/@denotest/basic/1.0.0.tgz | ||
Download http://localhost:4262/@denotest2/basic/1.0.0.tgz | ||
Initialize @denotest2/[email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
@denotest:registry=http://127.0.0.1:4261/ | ||
@denotest:registry=http://localhost:4261/ | ||
; This configuration is wrong - the registry URL must | ||
; be exactly the same as registry configured for the scope, | ||
; not root url + scope name. | ||
//127.0.0.1:4261/denotest/:_authToken=invalid-token | ||
//localhost:4261/denotest/:_authToken=invalid-token |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
⚠️ `deno install` behavior will change in Deno 2. To preserve the current behavior use the `-g` or `--global` flag. | ||
Download http://127.0.0.1:4261/@denotest/basic | ||
error: Error getting response at http://127.0.0.1:4261/@denotest/basic for package "@denotest/basic": Bad response: 401 | ||
Download http://localhost:4261/@denotest/basic | ||
error: Error getting response at http://localhost:4261/@denotest/basic for package "@denotest/basic": Bad response: 401 | ||
[WILDCARD] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
@denotest:registry=http://127.0.0.1:4261/ | ||
//127.0.0.1:4261/:_authToken=invalid-token | ||
@denotest:registry=http://localhost:4261/ | ||
//localhost:4261/:_authToken=invalid-token |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
⚠️ `deno install` behavior will change in Deno 2. To preserve the current behavior use the `-g` or `--global` flag. | ||
Download http://127.0.0.1:4261/@denotest/basic | ||
error: Error getting response at http://127.0.0.1:4261/@denotest/basic for package "@denotest/basic": Bad response: 401 | ||
Download http://localhost:4261/@denotest/basic | ||
error: Error getting response at http://localhost:4261/@denotest/basic for package "@denotest/basic": Bad response: 401 | ||
[WILDCARD] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
@denotest:registry=http://127.0.0.1:4261/ | ||
//127.0.0.1:4261/:_auth=ZGVubzpsYW5k | ||
@denotest2:registry=http://127.0.0.1:4262/ | ||
//127.0.0.1:4262/:_auth=ZGVubzpsYW5kMg== | ||
@denotest:registry=http://localhost:4261/ | ||
//localhost:4261/:_auth=ZGVubzpsYW5k | ||
@denotest2:registry=http://localhost:4262/ | ||
//localhost:4262/:_auth=ZGVubzpsYW5kMg== |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
⚠️ `deno install` behavior will change in Deno 2. To preserve the current behavior use the `-g` or `--global` flag. | ||
[UNORDERED_START] | ||
Download http://127.0.0.1:4261/@denotest/basic | ||
Download http://127.0.0.1:4262/@denotest2/basic | ||
Download http://localhost:4261/@denotest/basic | ||
Download http://localhost:4262/@denotest2/basic | ||
Download http://localhost:4261/@denotest/basic/1.0.0.tgz | ||
Download http://localhost:4262/@denotest2/basic/1.0.0.tgz | ||
Initialize @denotest2/[email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
@denotest:registry=http://127.0.0.1:4261/ | ||
//127.0.0.1:4261/:_authToken=private-reg-token | ||
@denotest:registry=http://localhost:4261/ | ||
//localhost:4261/:_authToken=private-reg-token |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
Download http://127.0.0.1:4261/@denotest/basic | ||
Download http://localhost:4261/@denotest/basic | ||
Download http://localhost:4261/@denotest/basic/1.0.0.tgz | ||
0 | ||
42 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
@denotest:registry=http://127.0.0.1:4261/ | ||
//127.0.0.1:4261/:_authToken=private-reg-token | ||
@denotest:registry=http://localhost:4261/ | ||
//localhost:4261/:_authToken=private-reg-token |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
{ | ||
"tempDir": true, | ||
"tests": { | ||
"auth_success": { | ||
"cwd": "success", | ||
"args": "run --node-modules-dir -A main.js", | ||
"output": "success/main.out", | ||
"exitCode": 1 | ||
}, | ||
"auth_fail": { | ||
"cwd": "fail", | ||
"args": "run --node-modules-dir -A main.js", | ||
"output": "fail/main.out", | ||
"exitCode": 1 | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
@denotest:registry=http://localhost:4261/ | ||
//localhost:4261/:_authToken=private-reg-token |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import getValue from "@denotest/tarballs-privateserver2"; | ||
|
||
console.log(getValue()); |
Oops, something went wrong.