diff --git a/.changeset/late-berries-rule.md b/.changeset/late-berries-rule.md deleted file mode 100644 index e632ac89..00000000 --- a/.changeset/late-berries-rule.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'proxy-agent': minor ---- - -Lazily load agents in proxy-agent diff --git a/.changeset/pretty-terms-exercise.md b/.changeset/pretty-terms-exercise.md deleted file mode 100644 index f4642d44..00000000 --- a/.changeset/pretty-terms-exercise.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'agent-base': patch ---- - -Handle exceptions caused by Agent.addRequest() diff --git a/.changeset/sixty-carpets-cross.md b/.changeset/sixty-carpets-cross.md deleted file mode 100644 index 2dd6a905..00000000 --- a/.changeset/sixty-carpets-cross.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'proxy-agent': minor ---- - -Include ClientRequest in getProxyForUrl parameters for additional flexibility diff --git a/.changeset/swift-lizards-poke.md b/.changeset/swift-lizards-poke.md deleted file mode 100644 index 01410f02..00000000 --- a/.changeset/swift-lizards-poke.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'pac-proxy-agent': patch ---- - -Properly forward WebSocket requests via PAC agents that resolve to HTTP proxies diff --git a/.changeset/unlucky-vans-shout.md b/.changeset/unlucky-vans-shout.md deleted file mode 100644 index 0f2a5c81..00000000 --- a/.changeset/unlucky-vans-shout.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'proxy-agent': patch ---- - -Dispose of Agent instances in cache correctly diff --git a/packages/agent-base/CHANGELOG.md b/packages/agent-base/CHANGELOG.md index a4550a4f..93377983 100644 --- a/packages/agent-base/CHANGELOG.md +++ b/packages/agent-base/CHANGELOG.md @@ -1,5 +1,11 @@ # agent-base +## 7.1.2 + +### Patch Changes + +- 1699a09: Handle exceptions caused by Agent.addRequest() + ## 7.1.1 ### Patch Changes diff --git a/packages/agent-base/package.json b/packages/agent-base/package.json index 91996ef7..590e5e1d 100644 --- a/packages/agent-base/package.json +++ b/packages/agent-base/package.json @@ -1,6 +1,6 @@ { "name": "agent-base", - "version": "7.1.1", + "version": "7.1.2", "description": "Turn a function into an `http.Agent` instance", "main": "./dist/index.js", "types": "./dist/index.d.ts", diff --git a/packages/pac-proxy-agent/CHANGELOG.md b/packages/pac-proxy-agent/CHANGELOG.md index b7105325..3f8e862a 100644 --- a/packages/pac-proxy-agent/CHANGELOG.md +++ b/packages/pac-proxy-agent/CHANGELOG.md @@ -1,5 +1,13 @@ # pac-proxy-agent +## 7.0.3 + +### Patch Changes + +- e90e2b2: Properly forward WebSocket requests via PAC agents that resolve to HTTP proxies +- Updated dependencies [1699a09] + - agent-base@7.1.2 + ## 7.0.2 ### Patch Changes diff --git a/packages/pac-proxy-agent/package.json b/packages/pac-proxy-agent/package.json index 28feda20..471061c6 100644 --- a/packages/pac-proxy-agent/package.json +++ b/packages/pac-proxy-agent/package.json @@ -1,6 +1,6 @@ { "name": "pac-proxy-agent", - "version": "7.0.2", + "version": "7.0.3", "description": "A PAC file proxy `http.Agent` implementation for HTTP", "main": "./dist/index.js", "types": "./dist/index.d.ts", @@ -32,7 +32,7 @@ "license": "MIT", "dependencies": { "@tootallnate/quickjs-emscripten": "^0.23.0", - "agent-base": "^7.0.2", + "agent-base": "^7.1.2", "debug": "^4.3.4", "get-uri": "^6.0.1", "http-proxy-agent": "^7.0.0", diff --git a/packages/proxy-agent/CHANGELOG.md b/packages/proxy-agent/CHANGELOG.md index 1a4dcda0..cf025a3e 100644 --- a/packages/proxy-agent/CHANGELOG.md +++ b/packages/proxy-agent/CHANGELOG.md @@ -1,5 +1,20 @@ # proxy-agent +## 6.5.0 + +### Minor Changes + +- 85b10b3: Lazily load agents in proxy-agent +- 96b771b: Include ClientRequest in getProxyForUrl parameters for additional flexibility + +### Patch Changes + +- ad68f63: Dispose of Agent instances in cache correctly +- Updated dependencies [1699a09] +- Updated dependencies [e90e2b2] + - agent-base@7.1.2 + - pac-proxy-agent@7.0.3 + ## 6.4.0 ### Minor Changes diff --git a/packages/proxy-agent/package.json b/packages/proxy-agent/package.json index ecfac780..45e8a243 100644 --- a/packages/proxy-agent/package.json +++ b/packages/proxy-agent/package.json @@ -1,6 +1,6 @@ { "name": "proxy-agent", - "version": "6.4.0", + "version": "6.5.0", "description": "Maps proxy protocols to `http.Agent` implementations", "main": "./dist/index.js", "types": "./dist/index.d.ts", @@ -32,12 +32,12 @@ "author": "Nathan Rajlich (http://n8.io/)", "license": "MIT", "dependencies": { - "agent-base": "^7.0.2", + "agent-base": "^7.1.2", "debug": "^4.3.4", "http-proxy-agent": "^7.0.1", "https-proxy-agent": "^7.0.5", "lru-cache": "^7.14.1", - "pac-proxy-agent": "^7.0.2", + "pac-proxy-agent": "^7.0.3", "proxy-from-env": "^1.1.0", "socks-proxy-agent": "^8.0.4" }, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 90f9a954..a9e1ad60 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1,9 +1,5 @@ lockfileVersion: '6.0' -settings: - autoInstallPeers: true - excludeLinksFromLockfile: false - importers: .: @@ -13,10 +9,10 @@ importers: version: 2.26.2 '@typescript-eslint/eslint-plugin': specifier: ^5.59.1 - version: 5.60.1(@typescript-eslint/parser@5.60.1)(eslint@7.32.0)(typescript@5.1.6) + version: 5.60.1(@typescript-eslint/parser@5.60.1)(eslint@7.32.0) '@typescript-eslint/parser': specifier: ^5.59.1 - version: 5.60.1(eslint@7.32.0)(typescript@5.1.6) + version: 5.60.1(eslint@7.32.0) eslint: specifier: ^7.32.0 version: 7.32.0 @@ -62,7 +58,7 @@ importers: version: 29.5.0(@types/node@14.18.45) ts-jest: specifier: ^29.1.0 - version: 29.1.0(@babel/core@7.21.4)(jest@29.5.0)(typescript@5.0.4) + version: 29.1.0(jest@29.5.0)(typescript@5.0.4) tsconfig: specifier: workspace:* version: link:../tsconfig @@ -86,7 +82,7 @@ importers: version: 29.5.0(@types/node@14.18.45) ts-jest: specifier: ^29.1.0 - version: 29.1.0(@babel/core@7.22.5)(jest@29.5.0)(typescript@5.0.4) + version: 29.1.0(jest@29.5.0)(typescript@5.0.4) tsconfig: specifier: workspace:* version: link:../tsconfig @@ -126,7 +122,7 @@ importers: version: 29.5.0(@types/node@14.18.52) ts-jest: specifier: ^29.1.0 - version: 29.1.0(@babel/core@7.22.5)(jest@29.5.0)(typescript@5.1.6) + version: 29.1.0(jest@29.5.0)(typescript@5.1.6) tsconfig: specifier: workspace:* version: link:../tsconfig @@ -172,7 +168,7 @@ importers: version: 3.0.0 ts-jest: specifier: ^29.1.0 - version: 29.1.0(@babel/core@7.22.5)(jest@29.5.0)(typescript@5.0.4) + version: 29.1.0(jest@29.5.0)(typescript@5.0.4) tsconfig: specifier: workspace:* version: link:../tsconfig @@ -209,7 +205,7 @@ importers: version: link:../proxy ts-jest: specifier: ^29.1.0 - version: 29.1.0(@babel/core@7.22.5)(jest@29.5.0)(typescript@5.0.4) + version: 29.1.0(jest@29.5.0)(typescript@5.0.4) tsconfig: specifier: workspace:* version: link:../tsconfig @@ -252,7 +248,7 @@ importers: version: link:../proxy ts-jest: specifier: ^29.1.0 - version: 29.1.0(@babel/core@7.22.5)(jest@29.5.0)(typescript@5.0.4) + version: 29.1.0(jest@29.5.0)(typescript@5.0.4) tsconfig: specifier: workspace:* version: link:../tsconfig @@ -266,14 +262,14 @@ importers: specifier: ^0.23.0 version: 0.23.0 agent-base: - specifier: ^7.0.2 + specifier: ^7.1.2 version: link:../agent-base debug: specifier: ^4.3.4 version: 4.3.4 get-uri: specifier: ^6.0.1 - version: 6.0.4 + version: link:../get-uri http-proxy-agent: specifier: ^7.0.0 version: link:../http-proxy-agent @@ -310,7 +306,7 @@ importers: version: 0.0.6 ts-jest: specifier: ^29.1.0 - version: 29.1.0(@babel/core@7.22.5)(jest@29.5.0)(typescript@5.0.4) + version: 29.1.0(jest@29.5.0)(typescript@5.0.4) tsconfig: specifier: workspace:* version: link:../tsconfig @@ -344,7 +340,7 @@ importers: version: 29.5.0(@types/node@14.18.52) ts-jest: specifier: ^29.1.0 - version: 29.1.0(@babel/core@7.22.5)(jest@29.5.0)(typescript@5.1.6) + version: 29.1.0(jest@29.5.0)(typescript@5.1.6) tsconfig: specifier: workspace:* version: link:../tsconfig @@ -384,7 +380,7 @@ importers: version: 29.5.0(@types/node@14.18.45) ts-jest: specifier: ^29.1.0 - version: 29.1.0(@babel/core@7.22.5)(jest@29.5.0)(typescript@5.0.4) + version: 29.1.0(jest@29.5.0)(typescript@5.0.4) tsconfig: specifier: workspace:* version: link:../tsconfig @@ -395,7 +391,7 @@ importers: packages/proxy-agent: dependencies: agent-base: - specifier: ^7.0.2 + specifier: ^7.1.2 version: link:../agent-base debug: specifier: ^4.3.4 @@ -410,7 +406,7 @@ importers: specifier: ^7.14.1 version: 7.18.3 pac-proxy-agent: - specifier: ^7.0.2 + specifier: ^7.0.3 version: link:../pac-proxy-agent proxy-from-env: specifier: ^1.1.0 @@ -451,7 +447,7 @@ importers: version: github.com/TooTallNate/socksv5/d937368b28e929396166d77a06d387a4a902bd51 ts-jest: specifier: ^29.1.0 - version: 29.1.0(@babel/core@7.22.5)(jest@29.5.0)(typescript@5.0.4) + version: 29.1.0(jest@29.5.0)(typescript@5.0.4) tsconfig: specifier: workspace:* version: link:../tsconfig @@ -512,7 +508,7 @@ importers: version: github.com/TooTallNate/socksv5/d937368b28e929396166d77a06d387a4a902bd51 ts-jest: specifier: ^29.1.0 - version: 29.1.0(@babel/core@7.22.5)(jest@29.5.0)(typescript@5.0.4) + version: 29.1.0(jest@29.5.0)(typescript@5.0.4) tsconfig: specifier: workspace:* version: link:../tsconfig @@ -1975,7 +1971,7 @@ packages: '@types/yargs-parser': 21.0.0 dev: true - /@typescript-eslint/eslint-plugin@5.60.1(@typescript-eslint/parser@5.60.1)(eslint@7.32.0)(typescript@5.1.6): + /@typescript-eslint/eslint-plugin@5.60.1(@typescript-eslint/parser@5.60.1)(eslint@7.32.0): resolution: {integrity: sha512-KSWsVvsJsLJv3c4e73y/Bzt7OpqMCADUO846bHcuWYSYM19bldbAeDv7dYyV0jwkbMfJ2XdlzwjhXtuD7OY6bw==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -1987,23 +1983,22 @@ packages: optional: true dependencies: '@eslint-community/regexpp': 4.5.1 - '@typescript-eslint/parser': 5.60.1(eslint@7.32.0)(typescript@5.1.6) + '@typescript-eslint/parser': 5.60.1(eslint@7.32.0) '@typescript-eslint/scope-manager': 5.60.1 - '@typescript-eslint/type-utils': 5.60.1(eslint@7.32.0)(typescript@5.1.6) - '@typescript-eslint/utils': 5.60.1(eslint@7.32.0)(typescript@5.1.6) + '@typescript-eslint/type-utils': 5.60.1(eslint@7.32.0) + '@typescript-eslint/utils': 5.60.1(eslint@7.32.0) debug: 4.3.4 eslint: 7.32.0 grapheme-splitter: 1.0.4 ignore: 5.2.4 natural-compare-lite: 1.4.0 semver: 7.5.3 - tsutils: 3.21.0(typescript@5.1.6) - typescript: 5.1.6 + tsutils: 3.21.0 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/parser@5.60.1(eslint@7.32.0)(typescript@5.1.6): + /@typescript-eslint/parser@5.60.1(eslint@7.32.0): resolution: {integrity: sha512-pHWlc3alg2oSMGwsU/Is8hbm3XFbcrb6P5wIxcQW9NsYBfnrubl/GhVVD/Jm/t8HXhA2WncoIRfBtnCgRGV96Q==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -2015,10 +2010,9 @@ packages: dependencies: '@typescript-eslint/scope-manager': 5.60.1 '@typescript-eslint/types': 5.60.1 - '@typescript-eslint/typescript-estree': 5.60.1(typescript@5.1.6) + '@typescript-eslint/typescript-estree': 5.60.1 debug: 4.3.4 eslint: 7.32.0 - typescript: 5.1.6 transitivePeerDependencies: - supports-color dev: true @@ -2031,7 +2025,7 @@ packages: '@typescript-eslint/visitor-keys': 5.60.1 dev: true - /@typescript-eslint/type-utils@5.60.1(eslint@7.32.0)(typescript@5.1.6): + /@typescript-eslint/type-utils@5.60.1(eslint@7.32.0): resolution: {integrity: sha512-vN6UztYqIu05nu7JqwQGzQKUJctzs3/Hg7E2Yx8rz9J+4LgtIDFWjjl1gm3pycH0P3mHAcEUBd23LVgfrsTR8A==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -2041,12 +2035,11 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/typescript-estree': 5.60.1(typescript@5.1.6) - '@typescript-eslint/utils': 5.60.1(eslint@7.32.0)(typescript@5.1.6) + '@typescript-eslint/typescript-estree': 5.60.1 + '@typescript-eslint/utils': 5.60.1(eslint@7.32.0) debug: 4.3.4 eslint: 7.32.0 - tsutils: 3.21.0(typescript@5.1.6) - typescript: 5.1.6 + tsutils: 3.21.0 transitivePeerDependencies: - supports-color dev: true @@ -2056,7 +2049,7 @@ packages: engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true - /@typescript-eslint/typescript-estree@5.60.1(typescript@5.1.6): + /@typescript-eslint/typescript-estree@5.60.1: resolution: {integrity: sha512-hkX70J9+2M2ZT6fhti5Q2FoU9zb+GeZK2SLP1WZlvUDqdMbEKhexZODD1WodNRyO8eS+4nScvT0dts8IdaBzfw==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -2071,13 +2064,12 @@ packages: globby: 11.1.0 is-glob: 4.0.3 semver: 7.5.3 - tsutils: 3.21.0(typescript@5.1.6) - typescript: 5.1.6 + tsutils: 3.21.0 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/utils@5.60.1(eslint@7.32.0)(typescript@5.1.6): + /@typescript-eslint/utils@5.60.1(eslint@7.32.0): resolution: {integrity: sha512-tiJ7FFdFQOWssFa3gqb94Ilexyw0JVxj6vBzaSpfN/8IhoKkDuSAenUKvsSHw2A/TMpJb26izIszTXaqygkvpQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -2088,7 +2080,7 @@ packages: '@types/semver': 7.5.0 '@typescript-eslint/scope-manager': 5.60.1 '@typescript-eslint/types': 5.60.1 - '@typescript-eslint/typescript-estree': 5.60.1(typescript@5.1.6) + '@typescript-eslint/typescript-estree': 5.60.1 eslint: 7.32.0 eslint-scope: 5.1.1 semver: 7.5.3 @@ -2687,11 +2679,6 @@ packages: engines: {node: '>=0.4.0'} dev: true - /data-uri-to-buffer@6.0.2: - resolution: {integrity: sha512-7hvf7/GW8e86rW0ptuwS3OcBGDjIi6SZva7hCyWC0yYry2cOPmLIjXAUHI6DK2HsnwJd9ifmt57i8eV2n4YNpw==} - engines: {node: '>= 14'} - dev: false - /dateformat@1.0.7-1.2.3: resolution: {integrity: sha512-rzAoghPcnojOgYhvqb9ZYR5Ws9hDM2SGB6xLSUX9pEAKYnbxyexHZypDLgx3+SF3SR+at6waVRCxKDm6q2Z6+g==} dev: true @@ -3310,17 +3297,6 @@ packages: get-intrinsic: 1.2.1 dev: true - /get-uri@6.0.4: - resolution: {integrity: sha512-E1b1lFFLvLgak2whF2xDBcOy6NLVGZBqqjJjsIhvopKfWWEi64pLVTWWehV8KlLerZkfNTA95sTe2OdJKm1OzQ==} - engines: {node: '>= 14'} - dependencies: - basic-ftp: 5.0.2 - data-uri-to-buffer: 6.0.2 - debug: 4.3.4 - transitivePeerDependencies: - - supports-color - dev: false - /glob-parent@5.1.2: resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==} engines: {node: '>= 6'} @@ -5408,41 +5384,7 @@ packages: engines: {node: '>=8'} dev: true - /ts-jest@29.1.0(@babel/core@7.21.4)(jest@29.5.0)(typescript@5.0.4): - resolution: {integrity: sha512-ZhNr7Z4PcYa+JjMl62ir+zPiNJfXJN6E8hSLnaUKhOgqcn8vb3e537cpkd0FuAfRK3sR1LSqM1MOhliXNgOFPA==} - engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} - hasBin: true - peerDependencies: - '@babel/core': '>=7.0.0-beta.0 <8' - '@jest/types': ^29.0.0 - babel-jest: ^29.0.0 - esbuild: '*' - jest: ^29.0.0 - typescript: '>=4.3 <6' - peerDependenciesMeta: - '@babel/core': - optional: true - '@jest/types': - optional: true - babel-jest: - optional: true - esbuild: - optional: true - dependencies: - '@babel/core': 7.21.4 - bs-logger: 0.2.6 - fast-json-stable-stringify: 2.1.0 - jest: 29.5.0(@types/node@14.18.45) - jest-util: 29.5.0 - json5: 2.2.3 - lodash.memoize: 4.1.2 - make-error: 1.3.6 - semver: 7.5.0 - typescript: 5.0.4 - yargs-parser: 21.1.1 - dev: true - - /ts-jest@29.1.0(@babel/core@7.22.5)(jest@29.5.0)(typescript@5.0.4): + /ts-jest@29.1.0(jest@29.5.0)(typescript@5.0.4): resolution: {integrity: sha512-ZhNr7Z4PcYa+JjMl62ir+zPiNJfXJN6E8hSLnaUKhOgqcn8vb3e537cpkd0FuAfRK3sR1LSqM1MOhliXNgOFPA==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} hasBin: true @@ -5463,7 +5405,6 @@ packages: esbuild: optional: true dependencies: - '@babel/core': 7.22.5 bs-logger: 0.2.6 fast-json-stable-stringify: 2.1.0 jest: 29.5.0(@types/node@14.18.45) @@ -5476,7 +5417,7 @@ packages: yargs-parser: 21.1.1 dev: true - /ts-jest@29.1.0(@babel/core@7.22.5)(jest@29.5.0)(typescript@5.1.6): + /ts-jest@29.1.0(jest@29.5.0)(typescript@5.1.6): resolution: {integrity: sha512-ZhNr7Z4PcYa+JjMl62ir+zPiNJfXJN6E8hSLnaUKhOgqcn8vb3e537cpkd0FuAfRK3sR1LSqM1MOhliXNgOFPA==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} hasBin: true @@ -5497,7 +5438,6 @@ packages: esbuild: optional: true dependencies: - '@babel/core': 7.22.5 bs-logger: 0.2.6 fast-json-stable-stringify: 2.1.0 jest: 29.5.0(@types/node@14.18.52) @@ -5518,14 +5458,13 @@ packages: resolution: {integrity: sha512-7At1WUettjcSRHXCyYtTselblcHl9PJFFVKiCAy/bY97+BPZXSQ2wbq0P9s8tK2G7dFQfNnlJnPAiArVBVBsfA==} dev: false - /tsutils@3.21.0(typescript@5.1.6): + /tsutils@3.21.0: resolution: {integrity: sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA==} engines: {node: '>= 6'} peerDependencies: typescript: '>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta' dependencies: tslib: 1.14.1 - typescript: 5.1.6 dev: true /tty-table@4.2.1: @@ -5968,3 +5907,7 @@ packages: dev: true bundledDependencies: - ipv6 + +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false