Skip to content

Commit

Permalink
fix(deps): update dependency got to v11 [security] (#4457)
Browse files Browse the repository at this point in the history
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [got](https://github.com/sindresorhus/got) | [`^10.7.0` ->
`^11.8.5`](https://renovatebot.com/diffs/npm/got/10.7.0/11.8.5) |
[![age](https://badges.renovateapi.com/packages/npm/got/11.8.5/age-slim)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://badges.renovateapi.com/packages/npm/got/11.8.5/adoption-slim)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://badges.renovateapi.com/packages/npm/got/11.8.5/compatibility-slim/10.7.0)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://badges.renovateapi.com/packages/npm/got/11.8.5/confidence-slim/10.7.0)](https://docs.renovatebot.com/merge-confidence/)
|

---

### ⚠ Dependency Lookup Warnings ⚠

Warnings were logged while processing this repo. Please check the
Dependency Dashboard for more information.

### GitHub Vulnerability Alerts

#### [CVE-2022-33987](https://nvd.nist.gov/vuln/detail/CVE-2022-33987)

The got package before 11.8.5 and 12.1.0 for Node.js allows a redirect
to a UNIX socket.

---

### Release Notes

<details>
<summary>sindresorhus/got</summary>

###
[`v11.8.5`](https://github.com/sindresorhus/got/releases/tag/v11.8.5)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.8.3...v11.8.5)

- Backport security fix
sindresorhus/got@861ccd9
- [CVE-2022-33987](https://nvd.nist.gov/vuln/detail/CVE-2022-33987)

###
[`v11.8.3`](https://github.com/sindresorhus/got/releases/tag/v11.8.3)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.8.2...v11.8.3)

- Bump cacheable-request dependency
([#&#8203;1921](https://github.com/sindresorhus/got/issues/1921))
[`9463bb6`](https://github.com/sindresorhus/got/commit/9463bb6)
- Fix `HTTPError` missing `.code` property
([#&#8203;1739](https://github.com/sindresorhus/got/issues/1739))
[`0e167b8`](https://github.com/sindresorhus/got/commit/0e167b8)

###
[`v11.8.2`](https://github.com/sindresorhus/got/releases/tag/v11.8.2)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.8.1...v11.8.2)

- Make the `dnsCache` option lazy
([#&#8203;1529](https://github.com/sindresorhus/got/issues/1529))
[`3bd245f`](https://github.com/sindresorhus/got/commit/3bd245f)
This slightly improves Got startup performance and fixes an issue with
Jest.

###
[`v11.8.1`](https://github.com/sindresorhus/got/releases/tag/v11.8.1)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.8.0...v11.8.1)

- Do not throw on custom stack traces
([#&#8203;1491](https://github.com/sindresorhus/got/issues/1491))
[`4c815c3`](https://github.com/sindresorhus/got/commit/4c815c3a609eb74d0eb139414d9996b4f65dc3c0)

###
[`v11.8.0`](https://github.com/sindresorhus/got/releases/tag/v11.8.0)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.7.0...v11.8.0)

- Fix for sending files with size `0` on `stat`
([#&#8203;1488](https://github.com/sindresorhus/got/issues/1488))
[`7acd380`](https://github.com/sindresorhus/got/commit/7acd380)
- `beforeRetry` allows stream body if different from original
([#&#8203;1501](https://github.com/sindresorhus/got/issues/1501))
[`3dd2273`](https://github.com/sindresorhus/got/commit/3dd2273)
- Set default value for an options object
([#&#8203;1495](https://github.com/sindresorhus/got/issues/1495))
[`390b145`](https://github.com/sindresorhus/got/commit/390b145)

###
[`v11.7.0`](https://github.com/sindresorhus/got/releases/tag/v11.7.0)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.6.2...v11.7.0)

##### Improvements

- Add [`pfx`](https://github.com/sindresorhus/got#httpspfx) HTTPS
option
([#&#8203;1364](https://github.com/sindresorhus/got/issues/1364))
[`c33df7f`](https://github.com/sindresorhus/got/commit/c33df7f)
- Update `body` after `beforeRequest`
([#&#8203;1453](https://github.com/sindresorhus/got/issues/1453))
[`e1c1844`](https://github.com/sindresorhus/got/commit/e1c1844)
- Don't allocate buffer twice
([#&#8203;1403](https://github.com/sindresorhus/got/issues/1403))
[`7bc69d9`](https://github.com/sindresorhus/got/commit/7bc69d9)

##### Fixes

- Fix a regression where body was sent after redirect
[`88b32ea`](https://github.com/sindresorhus/got/commit/88b32ea)
- Fix destructure error on `promise.json()`
[`c97ce7c`](https://github.com/sindresorhus/got/commit/c97ce7c)
- Do not ignore userinfo on a redirect to the same origin
[`52de13b`](https://github.com/sindresorhus/got/commit/52de13b)

###
[`v11.6.2`](https://github.com/sindresorhus/got/releases/tag/v11.6.2)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.6.1...v11.6.2)

##### Bug fixes

- Inherit the `prefixUrl` option from parent if it's `undefined`
([#&#8203;1448](https://github.com/sindresorhus/got/issues/1448))
[`a3da70a`](https://github.com/sindresorhus/got/commit/a3da70a78aeb7f44dd3e0d0fa47cebe9541eb91e)
- Prepare a fix for hanging promise on Node.js 14.10.x
[`29d4e32`](https://github.com/sindresorhus/got/commit/29d4e325b110ccf7571d4265d40760be4175f7ff)
- Prepare for Node.js 15.0.0
[`c126ff1`](https://github.com/sindresorhus/got/commit/c126ff19c4e893975cbf6c2c8bebce6ed7631276)

##### Docs

- Point travis-ci.org badge to travis-ci.com
([#&#8203;1442](https://github.com/sindresorhus/got/issues/1442))
[`2b352d3`](https://github.com/sindresorhus/got/commit/2b352d3f9e216e116efc0249a3a78b8d4492f97c)
- Clarify the retry mechanism
[`f248618`](https://github.com/sindresorhus/got/commit/f2486180207dba30624901761a457694096441c1)
- Fix `RequestError` links
[`3ed4af6`](https://github.com/sindresorhus/got/commit/3ed4af605ca6493c080cc8003a55c3b37988efee)

##### Tests

- Downgrade Travis CI Node.js version to 14.9.0
([#&#8203;1454](https://github.com/sindresorhus/got/issues/1454))
[`27470b5`](https://github.com/sindresorhus/got/commit/27470b53e1bcd6f435fc77006c9e3e864961dbec)

###
[`v11.6.1`](https://github.com/sindresorhus/got/releases/tag/v11.6.1)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.6.0...v11.6.1)

##### Fixes

- Fix `options.port` on redirect
([#&#8203;1439](https://github.com/sindresorhus/got/issues/1439))
[`408e22a`](https://github.com/sindresorhus/got/commit/408e22a)

##### Meta

- Welcome [@&#8203;Giotino](https://github.com/Giotino) as a
maintainer 🎉
[`5031843`](https://github.com/sindresorhus/got/commit/5031843)
- Showcase companies using Got
([#&#8203;1432](https://github.com/sindresorhus/got/issues/1432))
[`d12d6af`](https://github.com/sindresorhus/got/commit/d12d6af)

###
[`v11.6.0`](https://github.com/sindresorhus/got/releases/tag/v11.6.0)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.5.2...v11.6.0)

##### Improvements

- Add `retry` stream event
([#&#8203;1384](https://github.com/sindresorhus/got/issues/1384))
[`7072198`](https://github.com/sindresorhus/got/commit/707219825b2f8ff3df597230a53244636df21642)
- Add types for `http-cache-semantics` options
[`2e2295f`](https://github.com/sindresorhus/got/commit/2e2295fba63c260d347fef2081cdbcae45fa6116)
- Make `CancelError` inherit `RequestError`
[`1f132e8`](https://github.com/sindresorhus/got/commit/1f132e88b4e9b295631637757d64307032a4e56e)
- Add `retryAfter` to `RetryObject`
[`643a305`](https://github.com/sindresorhus/got/commit/643a305b4d710042d2a958a21e7637183713505c)
- Add documentation comments to exported TypeScript types
([#&#8203;1278](https://github.com/sindresorhus/got/issues/1278))
[`eaf1e02`](https://github.com/sindresorhus/got/commit/eaf1e02b21e4b8c08197c6400844d4098828ecf4)
- Move cache options into a `cacheOptions` property
[`9c16d90`](https://github.com/sindresorhus/got/commit/9c16d9083019fcb28f566659106036faa4839447)

##### Bug fixes

- Got promise shouldn't retry when the body is a stream
[`6e1aeae`](https://github.com/sindresorhus/got/commit/6e1aeaedb5dfe4f4b15eecf72a80303c30df22af)

##### Docs

- Add an example of nock integration with retrying
[`f7bbc37`](https://github.com/sindresorhus/got/commit/f7bbc3753779e14b22d7aa337764c7048aebb915)
- Fix `CancelError` docs
[`28c400f`](https://github.com/sindresorhus/got/commit/28c400f4df5f45990f80641a794a2d09439bef93)
- Fix retry delay function in the `README`
([#&#8203;1425](https://github.com/sindresorhus/got/issues/1425))
[`38bbb04`](https://github.com/sindresorhus/got/commit/38bbb04ea24f01eed6f01e394bc3e9405df8cfc5)

###
[`v11.5.2`](https://github.com/sindresorhus/got/releases/tag/v11.5.2)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.5.1...v11.5.2)

##### Docs

- Add hpagent to proxy section
([#&#8203;1363](https://github.com/sindresorhus/got/issues/1363))
[`a3e171c`](https://github.com/sindresorhus/got/commit/a3e171c4d43c8bbb236ef3a04feb25ba6fdf6c49)
- Mention header lowercasing in`request` migration guide
([#&#8203;1387](https://github.com/sindresorhus/got/issues/1387))
[`a748343`](https://github.com/sindresorhus/got/commit/a748343363ecb0347897264fb49df4a8f4793997)
- Fixed deprecationWarning on https options
([#&#8203;1391](https://github.com/sindresorhus/got/issues/1391))
[`9a309bd`](https://github.com/sindresorhus/got/commit/9a309bdbe7e2552c5bffbea253d58c39d6e6c3e3)

##### Bug fixes

- Fix duplicated hooks when paginating
[`e02845f`](https://github.com/sindresorhus/got/commit/e02845f1aa737d55dce23381d0f4f2a61b1eb5e1)
- Fix `dnsCache: true` having no effect
[`043c950`](https://github.com/sindresorhus/got/commit/043c9501b85172e09819d44ac8eb49c574b27bda)

###
[`v11.5.1`](https://github.com/sindresorhus/got/releases/tag/v11.5.1)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.5.0...v11.5.1)

##### Enhancements

- Upgrade `http2-wrapper` to `1.0.0-beta.5.0`
[`16e7f03`](https://github.com/sindresorhus/got/commit/16e7f031bb371571e1948091b88385be3485d83f)
- Compatibility fix to ignore incorrect Node.js 12 typings
[`f7a1379`](https://github.com/sindresorhus/got/commit/f7a1379e417641613bf1b654e37f37a7e6447e0c)
[`61d6f61`](https://github.com/sindresorhus/got/commit/61d6f610ffa6b760d466ff910a8e959778ee36e0)

##### Bug fixes

- Prevent uncaught errors on HTTP errors
[`2d96679`](https://github.com/sindresorhus/got/commit/2d96679c0a007be657835e83c6afb20b4510e9c5)
[`1ef053d`](https://github.com/sindresorhus/got/commit/1ef053d2af7f9b050ce0a3d1884f45b285f2e775)

##### Docs

- Mention HTTP/2 proxying in `readme.md`
[`4ebd26a`](https://github.com/sindresorhus/got/commit/4ebd26a4b8eef704fe216d333e2614b39dedf695)
- Update the comparison table
[`bd2d532`](https://github.com/sindresorhus/got/commit/bd2d53269882e48af88ff736a2e82aecd9e1fbee)
[`c833939`](https://github.com/sindresorhus/got/commit/c83393933c2b308a312ed4dc85d852c79445e400)
- Document the hierarchy of error classes
([#&#8203;1359](https://github.com/sindresorhus/got/issues/1359))
[`559526e`](https://github.com/sindresorhus/got/commit/559526ee273fb60d152759d288bc76971abb99e2)
- Fix example code for HTTPS proxy
([#&#8203;1360](https://github.com/sindresorhus/got/issues/1360))
[`4083347`](https://github.com/sindresorhus/got/commit/408334756ace0570ca4a0aded5a8aeac437eac33)

###
[`v11.5.0`](https://github.com/sindresorhus/got/releases/tag/v11.5.0)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.4.0...v11.5.0)

##### Improvements

- Add `backoff` option to pagination
([#&#8203;1182](https://github.com/sindresorhus/got/issues/1182))
[`4be7446`](https://github.com/sindresorhus/got/commit/4be7446)
- Upgrade dependencies
([#&#8203;1345](https://github.com/sindresorhus/got/issues/1345))
[`b9a855d`](https://github.com/sindresorhus/got/commit/b9a855d)
[`476c026`](https://github.com/sindresorhus/got/commit/476c026)
[`8d697bc`](https://github.com/sindresorhus/got/commit/8d697bc)
- Upgrade to TypeScript 3.9
([#&#8203;1267](https://github.com/sindresorhus/got/issues/1267))
[`b51d836`](https://github.com/sindresorhus/got/commit/b51d836)

##### Fixes

- Fix TypeScript types for Promise API
([#&#8203;1344](https://github.com/sindresorhus/got/issues/1344))
[`676be6d`](https://github.com/sindresorhus/got/commit/676be6d)
- Fix cache not working with HTTP2
[`ac5f67d`](https://github.com/sindresorhus/got/commit/ac5f67d)
- Fix `response` event not being emitted on cache verify request
([#&#8203;1305](https://github.com/sindresorhus/got/issues/1305))
[`da4769e`](https://github.com/sindresorhus/got/commit/da4769e)
- Work around a bug in Node.js <=12.18.2
[`f33e8bc`](https://github.com/sindresorhus/got/commit/f33e8bc)
- Remove request error handler after response is downloaded
[`e1afe82`](https://github.com/sindresorhus/got/commit/e1afe82)
- Revert "Remove request error handler after response is downloaded"
[`aeb2e07`](https://github.com/sindresorhus/got/commit/aeb2e07)

##### Docs

- Mention advanced usage of a `beforeRequest` hook
[`779062a`](https://github.com/sindresorhus/got/commit/779062a)
- Mention to end the stream if there's no body
[`044767e`](https://github.com/sindresorhus/got/commit/044767e)

###
[`v11.4.0`](https://github.com/sindresorhus/got/releases/tag/v11.4.0)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.3.0...v11.4.0)

- Fix hanging promise on timeout on HTTP error
[`934211f`](https://github.com/sindresorhus/got/commit/934211f951bfd56751e90ec4eabe6379d8541a05)
- Use async iterators to get response body
([#&#8203;1256](https://github.com/sindresorhus/got/issues/1256))
[`7dcd145`](https://github.com/sindresorhus/got/commit/7dcd1456a68a2603d30cbb1a4e453c4560bd51b2)
- Fix promise not returning Buffer on compressed response
[`5028c11`](https://github.com/sindresorhus/got/commit/5028c11abd21c9d13bb3b12abb02961ec0465a8a)
- Clarify options.encoding docs
[`04f3ea4`](https://github.com/sindresorhus/got/commit/04f3ea4b7995e1609555dd13f00641b8f470de4c)
- Fix unhandled `The server aborted pending request` rejection
[`728aef9`](https://github.com/sindresorhus/got/commit/728aef989c1a6650d2b42a7f69b603075b5d35bf)
- Add missing `ECONNRESET` code to an abort error
[`d325d35`](https://github.com/sindresorhus/got/commit/d325d353a28e6038140aa5b18f2b6f9f796f10b6)
- Fix `prefixUrl` not working when the `url` argument is empty
[`8d3412a`](https://github.com/sindresorhus/got/commit/8d3412abb8aae3cefc75dd6f9e698988ed463dd6)
- Improve the `searchParams` option
[`4dbada9`](https://github.com/sindresorhus/got/commit/4dbada94e261ad890d2478c313ec3d74761b659e)
- Fix non-enumerable options \[such as body] not being used
[`8f775c7`](https://github.com/sindresorhus/got/commit/8f775c71c41a377186c6b38c6789542bfd523039)

###
[`v11.3.0`](https://github.com/sindresorhus/got/releases/tag/v11.3.0)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.2.0...v11.3.0)

- Deep merge `https` options
([#&#8203;1304](https://github.com/sindresorhus/got/issues/1304))
[`c98f0d7`](https://github.com/sindresorhus/got/commit/c98f0d7)
- Add options to customize [parsing/stringifying
JSON](https://github.com/sindresorhus/got#parsejson)
([#&#8203;1298](https://github.com/sindresorhus/got/issues/1298))
[`cb4da8d`](https://github.com/sindresorhus/got/commit/cb4da8d)
- Add
[`dnsLookupIpVersion`](https://github.com/sindresorhus/got#dnslookupipversion)
option
([#&#8203;1264](https://github.com/sindresorhus/got/issues/1264))
[`7f643bb`](https://github.com/sindresorhus/got/commit/7f643bb)

###
[`v11.2.0`](https://github.com/sindresorhus/got/releases/tag/v11.2.0)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.1.4...v11.2.0)

- Provide an overload for unknown `responseType`
([#&#8203;1276](https://github.com/sindresorhus/got/issues/1276))
[`b9ba18a`](https://github.com/sindresorhus/got/commit/b9ba18a)
- Fix overriding some options in a `beforeRequest` hook
([#&#8203;1293](https://github.com/sindresorhus/got/issues/1293))
[`d8c00cf`](https://github.com/sindresorhus/got/commit/d8c00cf)
- Fix hanging promise on aborted requests on Node v14.3.0
([#&#8203;1296](https://github.com/sindresorhus/got/issues/1296))
[`2ccc4c2`](https://github.com/sindresorhus/got/commit/2ccc4c2)
- Do not wait for `ready` event if the file descriptor is already opened
([#&#8203;1289](https://github.com/sindresorhus/got/issues/1289))
[`2c8fe19`](https://github.com/sindresorhus/got/commit/2c8fe19)
- General improvements to HTTPS API
([#&#8203;1255](https://github.com/sindresorhus/got/issues/1255))
[`697de37`](https://github.com/sindresorhus/got/commit/697de37)

###
[`v11.1.4`](https://github.com/sindresorhus/got/releases/tag/v11.1.4)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.1.3...v11.1.4)

- Clarify docs for got.HTTPError
([#&#8203;1244](https://github.com/sindresorhus/got/issues/1244))
[`3f125f1`](https://github.com/sindresorhus/got/commit/3f125f105e3b328942c04ef73579b1573fc39b5a)
- Upgrade `cacheable-lookup` to 5.0.3
[`9770e54`](https://github.com/sindresorhus/got/commit/9770e540d088c35ec0b467fa3d2fafb60ed6797d)
- Add a Runkit example
([#&#8203;1253](https://github.com/sindresorhus/got/issues/1253))
[`48bbb36`](https://github.com/sindresorhus/got/commit/48bbb369d715b8ec3c36e0af1ec88f47e2299172)
- Mention `options.rejectUnauthorized` in the documentation
[`9b04963`](https://github.com/sindresorhus/got/commit/9b049635570ebbdd9d534ad1860f01d34771a5ee)
- Test `responseType` set to `undefined`
[`0e8582f`](https://github.com/sindresorhus/got/commit/0e8582f24e6903d9079a7d92e9b4d831cb5b5f17)
- Slightly improve RunKit example
[`6f84051`](https://github.com/sindresorhus/got/commit/6f8405102517a1e61393ee7bdb5a4fcff08e64c5)
- Make `got.paginate()` an alias for `got.paginate.each()`
[`5480b31`](https://github.com/sindresorhus/got/commit/5480b3134cfd35497f618f08f574927c2bd7624b)
- Don't force query string normalization
([#&#8203;1246](https://github.com/sindresorhus/got/issues/1246))
[`761b8e0`](https://github.com/sindresorhus/got/commit/761b8e01f7d194dd3b9aa6578c26966ebae6172c)
- Upgrade `decompress-response` to `6.0.0`
[`c2bc014`](https://github.com/sindresorhus/got/commit/c2bc014abc8818ad93dd69a0e8cc9d36d0dccb9c)
- Migrate from `lolex` to `@sinonjs/fake-timers`
([#&#8203;1270](https://github.com/sindresorhus/got/issues/1270))
[`df333dd`](https://github.com/sindresorhus/got/commit/df333ddbc163e35537a9f49818e722c7aa6803c0)
- Make `calculateDelay` promisable
([#&#8203;1266](https://github.com/sindresorhus/got/issues/1266))
[`3745efc`](https://github.com/sindresorhus/got/commit/3745efc9d9d03c78c898f357a34524524cce514d)

###
[`v11.1.3`](https://github.com/sindresorhus/got/releases/tag/v11.1.3)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.1.2...v11.1.3)

- Do not use deprecated `request.abort()`
([#&#8203;1242](https://github.com/sindresorhus/got/issues/1242))
[`ab338a7`](https://github.com/sindresorhus/got/commit/ab338a70dd9547a6c48af18ab5e2306639e5cbad)
- Remove the `host` header on redirect
([#&#8203;1241](https://github.com/sindresorhus/got/issues/1241))
[`8ff71d9`](https://github.com/sindresorhus/got/commit/8ff71d972ae55700887b45d50a265e3659ac8cce)
- Prevent URL pollution
([#&#8203;1243](https://github.com/sindresorhus/got/issues/1243))
[`7dbb9ee`](https://github.com/sindresorhus/got/commit/7dbb9ee2bd58e8ee67ebfe734e0c62e765759593)
- Fix duplicated searchParams for pagination API
([#&#8203;1229](https://github.com/sindresorhus/got/issues/1229))
[`91aa0ac`](https://github.com/sindresorhus/got/commit/91aa0ac9e676130cd4cfc1183d16208c6167b31d)
- Add a test for stringified `searchParams` in merge
([#&#8203;1208](https://github.com/sindresorhus/got/issues/1208))
[`7d7361c`](https://github.com/sindresorhus/got/commit/7d7361cc3845421f24288fc39464a8b38bd75d56)
- Fix reusing options when paginating
[`8862270`](https://github.com/sindresorhus/got/commit/88622701c70434ddc1040c46ad16de0c0acd9143)
- Fix an invalid pagination test
[`47c1afe`](https://github.com/sindresorhus/got/commit/47c1afedc77b27a2eb3edd85064d8532da835045)
[`5131dc2`](https://github.com/sindresorhus/got/commit/5131dc2778a9b584acda062635a9458d5b22df0c)

###
[`v11.1.2`](https://github.com/sindresorhus/got/releases/tag/v11.1.2)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.1.1...v11.1.2)

##### Bug fixes

- Disable `options.dnsCache` by default
[`79507c2`](https://github.com/sindresorhus/got/commit/79507c2cdec137e65d715f36d13a5a0e577ddc01)

> This should stay disabled when making requests to internal hostnames
such as localhost, database.local etc.
> CacheableLookup uses dns.resolver4(..) and dns.resolver6(...) under
the hood and fall backs to dns.lookup(...) when the first two fail,
which may lead to additional delay.

##### Enhancements

- Add test cases for issues
[#&#8203;1221](https://github.com/sindresorhus/got/issues/1221) and
[#&#8203;1223](https://github.com/sindresorhus/got/issues/1223)
([#&#8203;1231](https://github.com/sindresorhus/got/issues/1231))
[`822bfa7`](https://github.com/sindresorhus/got/commit/822bfa770306737a3ad06196101975b669b5d738)
- Update dependencies
[`05ff878`](https://github.com/sindresorhus/got/commit/05ff8780768d48fb58c782ba0b9c141af44a7c15)

###
[`v11.1.1`](https://github.com/sindresorhus/got/releases/tag/v11.1.1)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.1.0...v11.1.1)

- Improve Node.js 14 compatibility
[`50ef99a`](https://github.com/sindresorhus/got/commit/50ef99a)
- Fix `got.mergeOptions()` regression
[`157e02b`](https://github.com/sindresorhus/got/commit/157e02b)
- Fix hanging promise when using cache
[`7b19e8f`](https://github.com/sindresorhus/got/commit/7b19e8f)
- Make `options.responseType` optional when using a template
[`9ed0a39`](https://github.com/sindresorhus/got/commit/9ed0a39)

###
[`v11.1.0`](https://github.com/sindresorhus/got/releases/tag/v11.1.0)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.0.3...v11.1.0)

- Add
[`pagination.stackAllItems`](https://github.com/sindresorhus/got#paginationstackallitems)
option
([#&#8203;1214](https://github.com/sindresorhus/got/issues/1214))
[`c1208d1`](https://github.com/sindresorhus/got/commit/c1208d1)
- Allow response body to be typed for pagination API
([#&#8203;1212](https://github.com/sindresorhus/got/issues/1212))
[`c127f5b`](https://github.com/sindresorhus/got/commit/c127f5b)
- Fix some options not working with the pagination API
[`278c421`](https://github.com/sindresorhus/got/commit/278c421)

###
[`v11.0.3`](https://github.com/sindresorhus/got/releases/tag/v11.0.3)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.0.2...v11.0.3)

##### Fixes

- Limit number of requests in pagination to prevent accidental overflows
([#&#8203;1181](https://github.com/sindresorhus/got/issues/1181))
[`4344c3a`](https://github.com/sindresorhus/got/commit/4344c3a)
- Fix promise rejecting before retry
[`b927e2d`](https://github.com/sindresorhus/got/commit/b927e2d)
- Fix `options.searchParams` duplicates
[`429db40`](https://github.com/sindresorhus/got/commit/429db40)
- Prevent calling `.abort()` on a destroyed request
[`63c1b72`](https://github.com/sindresorhus/got/commit/63c1b72)

##### Docs

- Fix incorrect usage in the readme examples
([#&#8203;1203](https://github.com/sindresorhus/got/issues/1203))
[`16ff82f`](https://github.com/sindresorhus/got/commit/16ff82f)
- Note that `cache` and `dnsCache` can be `false`
[`7c5290d`](https://github.com/sindresorhus/got/commit/7c5290d)

###
[`v11.0.2`](https://github.com/sindresorhus/got/releases/tag/v11.0.2)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.0.1...v11.0.2)

- Fix `response.statusMessage` being null
[`965bd03`](https://github.com/sindresorhus/got/commit/965bd03ad463afb9fdbe098a48b16269b54de9bd)
- Update the `http2-wrapper` dependency to `1.0.0-beta.4.4`
[`4e8de8e`](https://github.com/sindresorhus/got/commit/4e8de8e32cccaafddf0c6ef4f31716810ab4a14b)
- Use `Merge` as it's stricter than the intersection operator
[`d3b972e`](https://github.com/sindresorhus/got/commit/d3b972efaca28d8033468c7232a469e8cb034677)
- Prevent silent rejections in rare cases
[`8501c69`](https://github.com/sindresorhus/got/commit/8501c6901af4f7c74cd0ae3700b499bb42ce5928)
- Do not alter `options.body`
[`835c70b`](https://github.com/sindresorhus/got/commit/835c70bd6fdc5b1ba7e7ffd322490b6d66fb407e)

###
[`v11.0.1`](https://github.com/sindresorhus/got/releases/tag/v11.0.1)

[Compare
Source](https://github.com/sindresorhus/got/compare/v11.0.0...v11.0.1)

Fixed two regressions:

- `HTTPError`s have unspecified response body
([#&#8203;1162](https://github.com/sindresorhus/got/issues/1162))
- Options are duplicated while merging
([#&#8203;1163](https://github.com/sindresorhus/got/issues/1163))

[Improved TypeScript types for errors inherited from
`RequestError`](https://github.com/sindresorhus/got/commit/d914a7e7a0d97b03745b9b47623e4ac3532b4dae#diff-8eef38c70c64f535c3b8046b5ce40d9e)

###
[`v11.0.0`](https://github.com/sindresorhus/got/releases/tag/v11.0.0)

[Compare
Source](https://github.com/sindresorhus/got/compare/v10.7.0...v11.0.0)

Introducing Got 11! 🎉 The last major version was in December last
year. ❄️ Since then, a huge amount of bugs has been fixed.
There are also many new features, for example, **HTTP2 support** is
finally live! 🌐

*If you find Got useful, you might want to [sponsor the Got
maintainers](https://github.com/sindresorhus/got?sponsor=1).*

***

#### Breaking changes

##### Removed support for `electron.net`

Due to the inconsistencies between the Electron's `net` module and the
Node.js `http` module, we have decided to officially drop support for
it. Therefore, the `useElectronNet` option has been removed.

You'll still be able to use Got in the Electron main process and in the
renderer process through the `electron.remote` module or if you use
Node.js shims.

##### The Pagination API is now stable

We haven't seen any bugs yet, so please give it a try!
If you want to leave some feedback, you can do it
[here](https://github.com/sindresorhus/got/issues/1052). Any
suggestion is greatly appreciated!

```diff
 {
-    _pagination: {...}
+    pagination: {...}
 }
```

##### API

- The `options.encoding` behavior has been reverted back to the Got 9
behavior.
    In other words, the options is only meant for the Got promise API.
To set the encoding for streams, simply call
`stream.setEncoding(encoding)`.

```diff
-got.stream('https://sindresorhus.com', {encoding: 'base64'});
+got.stream('https://sindresorhus.com').setEncoding('base64');

// Promises stay untouched
await got('https://sindresorhus.com', {encoding: 'base64'});
```

- The error name `GotError` has been renamed to `RequestError` for
better readability and to comply with the documentation.

```diff
-const {GotError} = require('got');
+const {RequestError} = require('got');
```

- The `agent` option now accepts **only an object** with `http`, `https`
and `http2` properties.
While the `http` and `https` properties accept native `http(s).Agent`
instances, the `http2` property must be an instance of
[`http2wrapper.Agent`](https://github.com/szmarczak/http2-wrapper#new-http2agentoptions)
or be undefined.

```diff
{
-    agent: new https.Agent({keepAlive: true})
}

{
+    agent: {
+        http: new http.Agent({keepAlive: true}),
+        https: new https.Agent({keepAlive: true}),
+        http2: new http2wrapper.Agent()
+    }
}
```

- The `dnsCache` option is now set to a default instance of
[`CacheableLookup`](https://github.com/szmarczak/cacheable-lookup). It
cannot be a `Map`-like instance anymore. The underlying
[`cacheable-lookup`](https://github.com/szmarczak/cacheable-lookup)
package has received many improvements, for example, it has received
`hosts` file support! Additionally, the `cacheAdapter` option has been
renamed to `cache`. Note that it's no longer passed to
[Keyv](https://github.com/lukechilds/keyv), so you need to pass a Keyv
instance it if you want to save the data for later.

```diff
{
-    dnsCache: new CacheableLookup({
-        cacheAdapter: new Map()
-    })
}

{
+    dnsCache: new CacheableLookup({
+        cache: new Keyv({
+            cacheAdapter: new Map()
+        })
+    })
}

// Default:

{
    dnsCache: new CacheableLookup()
}
```

- Errors thrown in `init` hooks will be converted to instances of
`RequestError`. `RequestError`s provide much more useful information,
for example, you can access the Got options (through `error.options`),
which is very useful when debugging.

```js
const got = require('got');

(async () => {
    try {
        await got('https://sindresorhus.com', {
            hooks: {
                init: [
                    options => {
                        if (!options.context) {
                            throw new Error('You need to pass a `context` option');
                        }
                    }
                ]
            }
        });
    } catch (error) {
        console.log(`Request failed: ${error.message}`);
        console.log('Here are the options:', error.options);
    }
})();
```

- The options passed in an `init` hook may not have a `url` property. To
modify the request URL you should use a `beforeRequest` hook instead.

```diff
{
    hooks: {
-        init: [
+        beforeRequest: [
            options => {
                options.url = 'https://sindresorhus.com';
            }
        ]
    }
}
```

Note that this example shows a simple use case. In more complicated
algorithms, you need to split the `init` hook into another `init` hook
and a `beforeRequest` hook.

- The `error.request` property is no longer a `ClientRequest` instance.
Instead, it gives a Got stream, which provides a set of useful
properties.

```js
const got = require('got');

(async () => {
    try {
        await got('https://sindresorhus.com/notfound');
    } catch (error) {
        console.log(`Request failed: ${error.message}`);
        console.log('Download progress:', error.request.downloadProgress);
    }
})();
```

##### Renamed TypeScript types

Some of the TypeScript types have been renamed to improve the
readability:

<table>
<tr>
    <td>Old type</td>
    <td>New type</td>
</tr>
<tr>
    <td><code>ResponseObject</code></td>
    <td><code>Response</code></td>
</tr>
<tr>
    <td><code>Defaults</code></td>
    <td><code>InstanceDefaults</code></td>
</tr>
<tr>
    <td><code>DefaultOptions</code></td>
    <td><code>Defaults</code></td>
</tr>
<tr>
    <td><code>DefaultRetryOptions</code></td>
    <td><code>RequiredRetryOptions</code></td>
</tr>
<tr>
    <td><code>GotOptions</code></td>
    <td><code>Options</code></td>
</tr>
<tr>
    <td><code>GotRequestMethod</code></td>
    <td><code>GotRequestFunction</code></td>
</tr>
</table>

##### Other

-   Now requires Node.js 10.19 or later.

#### Enhancements

HTTP2 support is here! Excited? Yay! Unfortunately, it's off by default
to make the migration smoother. Many Got users have set up their own
Agents and we didn't want to break them. But fear no more, it will come
enabled by default in Got 12.

```js
const got = require('got');

(async () => {
    const response = await got('https://nghttp2.org/httpbin/anything', {http2: true});
    console.log(response.socket.alpnProtocol);
    //=> 'h2'
})();
```

1. The `merge` function is slow
([#&#8203;1016](https://github.com/sindresorhus/got/issues/1016))
2. Use `error.code` instead of `error.message` to compare errors
([#&#8203;981](https://github.com/sindresorhus/got/issues/981))
3. Pass error thrown in the `init` hook to `beforeError` hook
([#&#8203;929](https://github.com/sindresorhus/got/issues/929))
4. Errors have undefined body when using streams
([#&#8203;1138](https://github.com/sindresorhus/got/issues/1138))
5. Spaces should be normalized as `+` in query strings
([#&#8203;1113](https://github.com/sindresorhus/got/issues/1113))
6. Modify response headers while using `got.stream(...)`
([#&#8203;1129](https://github.com/sindresorhus/got/issues/1129))
7. Make `error.request` a Got stream
([`af0b147`](https://github.com/sindresorhus/got/commit/af0b1472abf48a6c5491dcb36a1d8863c5227fb3)).

#### Known bugs

1. When some errors occur, the `timings` may indicate that the request
was successful although it failed.
2. When some errors occur, the `downloadProgress` object may show
incorrect data.

#### Bug fixes

1. Requests to UNIX sockets are missing query strings
([#&#8203;1036](https://github.com/sindresorhus/got/issues/1036))
2. `beforeRequest` hooks aren't called on redirects
([#&#8203;994](https://github.com/sindresorhus/got/issues/994))
3. Errors are swallowed when using `stream.pipeline(got.stream(...),
...)`
([#&#8203;1026](https://github.com/sindresorhus/got/issues/1026))
4. Cannot use the `cache` along with the `body` option
([#&#8203;1021](https://github.com/sindresorhus/got/issues/1021))
5. Got doesn't throw on leading slashes
([#&#8203;1057](https://github.com/sindresorhus/got/issues/1057))
6. Got throws when passing already frozen options
([#&#8203;1050](https://github.com/sindresorhus/got/issues/1050))
7. Cannot type Got options properly due to missing types
([#&#8203;954](https://github.com/sindresorhus/got/issues/954))
8. `got.mergeOptions(...)` doesn't merge `URLSearchParams` instances
([#&#8203;1011](https://github.com/sindresorhus/got/issues/1011))
9. The `authorization` header is leaking
([#&#8203;1090](https://github.com/sindresorhus/got/issues/1090))
10. Pagination should ignore the `resolveBodyOnly` option
([#&#8203;1140](https://github.com/sindresorhus/got/issues/1140))
11. Cannot reuse user-provided options
([#&#8203;1118](https://github.com/sindresorhus/got/issues/1118))
12. Broken with Node.js ≥ 13.10.0
([#&#8203;1107](https://github.com/sindresorhus/got/issues/1107))
13. Cache is not decompressed
([#&#8203;1158](https://github.com/sindresorhus/got/issues/1158))
14. `beforeRetry` hooks are missing `options.context`
([#&#8203;1141](https://github.com/sindresorhus/got/issues/1141))
15. `promise.json()` doesn't throw `ParseError`
([#&#8203;1069](https://github.com/sindresorhus/got/issues/1069))
16. Not compatible with `tough-cookie@4.0.0`
([#&#8203;1131](https://github.com/sindresorhus/got/issues/1131))
17. Shortcuts give body from the failed request on token renewal
([#&#8203;1120](https://github.com/sindresorhus/got/issues/1120))
18. No effect when replacing the `cache` option in a Got instance
([#&#8203;1098](https://github.com/sindresorhus/got/issues/1098))
19. Memory leak when using `cache`
([#&#8203;1128](https://github.com/sindresorhus/got/issues/1128))
20. Got doesn't throw on aborted requests by the server
([#&#8203;1096](https://github.com/sindresorhus/got/issues/1096))

#### All changes

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "" (UTC), Automerge - At any time (no
schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://app.renovatebot.com/dashboard#github/vercel/turbo).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNS4zMi4xIiwidXBkYXRlZEluVmVyIjoiMzUuMzIuMiJ9-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
  • Loading branch information
renovate[bot] authored Apr 5, 2023
1 parent d5de4fa commit 0e0a9af
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 59 deletions.
2 changes: 1 addition & 1 deletion packages/create-turbo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"cross-spawn": "^7.0.3",
"execa": "5.1.1",
"fs-extra": "^10.1.0",
"got": "^10.7.0",
"got": "^11.8.5",
"gradient-string": "^2.0.0",
"inquirer": "^8.0.0",
"ora": "4.1.1",
Expand Down
90 changes: 32 additions & 58 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 0e0a9af

Please sign in to comment.