cloudstructs 0.5.0 → 0.5.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (150) hide show
  1. package/.jsii +7 -4
  2. package/assets/slack-app/provider.lambda/index.js +24 -3
  3. package/assets/slack-textract/detect.lambda/index.js +29 -8
  4. package/changelog.md +2 -6
  5. package/lib/codecommit-mirror/index.d.ts +1 -0
  6. package/lib/codecommit-mirror/index.d.ts.map +1 -0
  7. package/lib/codecommit-mirror/index.js +2 -2
  8. package/lib/ecs-service-roller/index.d.ts +1 -0
  9. package/lib/ecs-service-roller/index.d.ts.map +1 -0
  10. package/lib/ecs-service-roller/index.js +2 -2
  11. package/lib/email-receiver/index.d.ts +1 -0
  12. package/lib/email-receiver/index.d.ts.map +1 -0
  13. package/lib/email-receiver/receiver.d.ts +1 -0
  14. package/lib/email-receiver/receiver.d.ts.map +1 -0
  15. package/lib/email-receiver/receiver.js +1 -1
  16. package/lib/email-receiver/s3-function.d.ts +1 -0
  17. package/lib/email-receiver/s3-function.d.ts.map +1 -0
  18. package/lib/email-receiver/s3.lambda.d.ts +1 -0
  19. package/lib/email-receiver/s3.lambda.d.ts.map +1 -0
  20. package/lib/email-receiver/whitelist-function.d.ts +1 -0
  21. package/lib/email-receiver/whitelist-function.d.ts.map +1 -0
  22. package/lib/email-receiver/whitelist.lambda.d.ts +1 -0
  23. package/lib/email-receiver/whitelist.lambda.d.ts.map +1 -0
  24. package/lib/index.d.ts +1 -0
  25. package/lib/index.d.ts.map +1 -0
  26. package/lib/saml-identity-provider/index.d.ts +1 -0
  27. package/lib/saml-identity-provider/index.d.ts.map +1 -0
  28. package/lib/saml-identity-provider/index.js +2 -2
  29. package/lib/slack-app/index.d.ts +1 -0
  30. package/lib/slack-app/index.d.ts.map +1 -0
  31. package/lib/slack-app/manifest.d.ts +1 -0
  32. package/lib/slack-app/manifest.d.ts.map +1 -0
  33. package/lib/slack-app/manifest.js +1 -1
  34. package/lib/slack-app/provider-function.d.ts +1 -0
  35. package/lib/slack-app/provider-function.d.ts.map +1 -0
  36. package/lib/slack-app/provider.d.ts +1 -0
  37. package/lib/slack-app/provider.d.ts.map +1 -0
  38. package/lib/slack-app/provider.lambda.d.ts +1 -0
  39. package/lib/slack-app/provider.lambda.d.ts.map +1 -0
  40. package/lib/slack-app/slack-app.d.ts +1 -0
  41. package/lib/slack-app/slack-app.d.ts.map +1 -0
  42. package/lib/slack-app/slack-app.js +2 -2
  43. package/lib/slack-events/events-function.d.ts +1 -0
  44. package/lib/slack-events/events-function.d.ts.map +1 -0
  45. package/lib/slack-events/events.lambda.d.ts +1 -0
  46. package/lib/slack-events/events.lambda.d.ts.map +1 -0
  47. package/lib/slack-events/index.d.ts +1 -0
  48. package/lib/slack-events/index.d.ts.map +1 -0
  49. package/lib/slack-events/index.js +1 -1
  50. package/lib/slack-events/signature.d.ts +1 -0
  51. package/lib/slack-events/signature.d.ts.map +1 -0
  52. package/lib/slack-textract/detect-function.d.ts +1 -0
  53. package/lib/slack-textract/detect-function.d.ts.map +1 -0
  54. package/lib/slack-textract/detect.lambda.d.ts +1 -0
  55. package/lib/slack-textract/detect.lambda.d.ts.map +1 -0
  56. package/lib/slack-textract/index.d.ts +1 -0
  57. package/lib/slack-textract/index.d.ts.map +1 -0
  58. package/lib/slack-textract/index.js +1 -1
  59. package/lib/state-machine-cr-provider/index.d.ts +1 -0
  60. package/lib/state-machine-cr-provider/index.d.ts.map +1 -0
  61. package/lib/state-machine-cr-provider/index.js +1 -1
  62. package/lib/state-machine-cr-provider/runtime/http.d.ts +1 -0
  63. package/lib/state-machine-cr-provider/runtime/http.d.ts.map +1 -0
  64. package/lib/state-machine-cr-provider/runtime/index.d.ts +1 -0
  65. package/lib/state-machine-cr-provider/runtime/index.d.ts.map +1 -0
  66. package/lib/static-website/index.d.ts +1 -0
  67. package/lib/static-website/index.d.ts.map +1 -0
  68. package/lib/static-website/index.js +1 -1
  69. package/lib/static-website/origin-request-function.d.ts +1 -0
  70. package/lib/static-website/origin-request-function.d.ts.map +1 -0
  71. package/lib/static-website/origin-request.edge-lambda.d.ts +1 -0
  72. package/lib/static-website/origin-request.edge-lambda.d.ts.map +1 -0
  73. package/lib/toolkit-cleaner/clean-images-function.d.ts +1 -0
  74. package/lib/toolkit-cleaner/clean-images-function.d.ts.map +1 -0
  75. package/lib/toolkit-cleaner/clean-images.lambda.d.ts +1 -0
  76. package/lib/toolkit-cleaner/clean-images.lambda.d.ts.map +1 -0
  77. package/lib/toolkit-cleaner/clean-objects-function.d.ts +1 -0
  78. package/lib/toolkit-cleaner/clean-objects-function.d.ts.map +1 -0
  79. package/lib/toolkit-cleaner/clean-objects.lambda.d.ts +1 -0
  80. package/lib/toolkit-cleaner/clean-objects.lambda.d.ts.map +1 -0
  81. package/lib/toolkit-cleaner/extract-template-hashes-function.d.ts +1 -0
  82. package/lib/toolkit-cleaner/extract-template-hashes-function.d.ts.map +1 -0
  83. package/lib/toolkit-cleaner/extract-template-hashes.lambda.d.ts +1 -0
  84. package/lib/toolkit-cleaner/extract-template-hashes.lambda.d.ts.map +1 -0
  85. package/lib/toolkit-cleaner/get-stack-names-function.d.ts +1 -0
  86. package/lib/toolkit-cleaner/get-stack-names-function.d.ts.map +1 -0
  87. package/lib/toolkit-cleaner/get-stack-names.lambda.d.ts +1 -0
  88. package/lib/toolkit-cleaner/get-stack-names.lambda.d.ts.map +1 -0
  89. package/lib/toolkit-cleaner/index.d.ts +1 -0
  90. package/lib/toolkit-cleaner/index.d.ts.map +1 -0
  91. package/lib/toolkit-cleaner/index.js +1 -1
  92. package/lib/url-shortener/index.d.ts +1 -0
  93. package/lib/url-shortener/index.d.ts.map +1 -0
  94. package/lib/url-shortener/index.js +1 -1
  95. package/lib/url-shortener/redirect-function.d.ts +1 -0
  96. package/lib/url-shortener/redirect-function.d.ts.map +1 -0
  97. package/lib/url-shortener/redirect.edge-lambda.d.ts +1 -0
  98. package/lib/url-shortener/redirect.edge-lambda.d.ts.map +1 -0
  99. package/lib/url-shortener/shortener-function.d.ts +1 -0
  100. package/lib/url-shortener/shortener-function.d.ts.map +1 -0
  101. package/lib/url-shortener/shortener.lambda.d.ts +1 -0
  102. package/lib/url-shortener/shortener.lambda.d.ts.map +1 -0
  103. package/node_modules/@slack/logger/node_modules/@types/node/README.md +2 -2
  104. package/node_modules/@slack/logger/node_modules/@types/node/index.d.ts +1 -0
  105. package/node_modules/@slack/logger/node_modules/@types/node/net.d.ts +5 -0
  106. package/node_modules/@slack/logger/node_modules/@types/node/package.json +7 -2
  107. package/node_modules/@slack/logger/node_modules/@types/node/stream.d.ts +13 -0
  108. package/node_modules/@slack/logger/node_modules/@types/node/timers.d.ts +3 -3
  109. package/node_modules/@slack/web-api/node_modules/@types/node/README.md +2 -2
  110. package/node_modules/@slack/web-api/node_modules/@types/node/index.d.ts +1 -0
  111. package/node_modules/@slack/web-api/node_modules/@types/node/net.d.ts +5 -0
  112. package/node_modules/@slack/web-api/node_modules/@types/node/package.json +7 -2
  113. package/node_modules/@slack/web-api/node_modules/@types/node/stream.d.ts +13 -0
  114. package/node_modules/@slack/web-api/node_modules/@types/node/timers.d.ts +3 -3
  115. package/node_modules/@types/cacheable-request/node_modules/@types/node/README.md +2 -2
  116. package/node_modules/@types/cacheable-request/node_modules/@types/node/index.d.ts +1 -0
  117. package/node_modules/@types/cacheable-request/node_modules/@types/node/net.d.ts +5 -0
  118. package/node_modules/@types/cacheable-request/node_modules/@types/node/package.json +7 -2
  119. package/node_modules/@types/cacheable-request/node_modules/@types/node/stream.d.ts +13 -0
  120. package/node_modules/@types/cacheable-request/node_modules/@types/node/timers.d.ts +3 -3
  121. package/node_modules/@types/is-stream/node_modules/@types/node/README.md +2 -2
  122. package/node_modules/@types/is-stream/node_modules/@types/node/index.d.ts +1 -0
  123. package/node_modules/@types/is-stream/node_modules/@types/node/net.d.ts +5 -0
  124. package/node_modules/@types/is-stream/node_modules/@types/node/package.json +7 -2
  125. package/node_modules/@types/is-stream/node_modules/@types/node/stream.d.ts +13 -0
  126. package/node_modules/@types/is-stream/node_modules/@types/node/timers.d.ts +3 -3
  127. package/node_modules/@types/keyv/node_modules/@types/node/README.md +2 -2
  128. package/node_modules/@types/keyv/node_modules/@types/node/index.d.ts +1 -0
  129. package/node_modules/@types/keyv/node_modules/@types/node/net.d.ts +5 -0
  130. package/node_modules/@types/keyv/node_modules/@types/node/package.json +7 -2
  131. package/node_modules/@types/keyv/node_modules/@types/node/stream.d.ts +13 -0
  132. package/node_modules/@types/keyv/node_modules/@types/node/timers.d.ts +3 -3
  133. package/node_modules/@types/responselike/node_modules/@types/node/README.md +2 -2
  134. package/node_modules/@types/responselike/node_modules/@types/node/index.d.ts +1 -0
  135. package/node_modules/@types/responselike/node_modules/@types/node/net.d.ts +5 -0
  136. package/node_modules/@types/responselike/node_modules/@types/node/package.json +7 -2
  137. package/node_modules/@types/responselike/node_modules/@types/node/stream.d.ts +13 -0
  138. package/node_modules/@types/responselike/node_modules/@types/node/timers.d.ts +3 -3
  139. package/node_modules/follow-redirects/index.js +14 -9
  140. package/node_modules/follow-redirects/package.json +1 -1
  141. package/node_modules/got/dist/source/as-promise/index.js +1 -1
  142. package/node_modules/got/dist/source/core/index.js +8 -0
  143. package/node_modules/got/dist/source/types.d.ts +8 -8
  144. package/node_modules/got/package.json +1 -1
  145. package/node_modules/keyv/package.json +4 -1
  146. package/node_modules/keyv/src/index.d.ts +7 -1
  147. package/node_modules/keyv/src/index.js +3 -2
  148. package/package.json +16 -9
  149. package/releasetag.txt +1 -1
  150. package/version.txt +1 -1
@@ -1238,6 +1238,19 @@ declare module 'stream' {
1238
1238
  ref(): void;
1239
1239
  unref(): void;
1240
1240
  }
1241
+
1242
+ /**
1243
+ * Returns whether the stream has encountered an error.
1244
+ * @since v17.3.0
1245
+ */
1246
+ function isErrored(stream: Readable | Writable | NodeJS.ReadableStream | NodeJS.WritableStream): boolean;
1247
+
1248
+ /**
1249
+ * Returns whether the stream is readable.
1250
+ * @since v17.4.0
1251
+ */
1252
+ function isReadable(stream: Readable | NodeJS.ReadableStream): boolean;
1253
+
1241
1254
  const promises: typeof streamPromises;
1242
1255
  const consumers: typeof streamConsumers;
1243
1256
  }
@@ -69,7 +69,7 @@ declare module 'timers' {
69
69
  namespace setTimeout {
70
70
  const __promisify__: typeof setTimeoutPromise;
71
71
  }
72
- function clearTimeout(timeoutId: NodeJS.Timeout): void;
72
+ function clearTimeout(timeoutId: NodeJS.Timeout | undefined): void;
73
73
  function setInterval<TArgs extends any[]>(callback: (...args: TArgs) => void, ms?: number, ...args: TArgs): NodeJS.Timer;
74
74
  // util.promisify no rest args compability
75
75
  // tslint:disable-next-line void-return
@@ -77,7 +77,7 @@ declare module 'timers' {
77
77
  namespace setInterval {
78
78
  const __promisify__: typeof setIntervalPromise;
79
79
  }
80
- function clearInterval(intervalId: NodeJS.Timeout): void;
80
+ function clearInterval(intervalId: NodeJS.Timeout | undefined): void;
81
81
  function setImmediate<TArgs extends any[]>(callback: (...args: TArgs) => void, ...args: TArgs): NodeJS.Immediate;
82
82
  // util.promisify no rest args compability
83
83
  // tslint:disable-next-line void-return
@@ -85,7 +85,7 @@ declare module 'timers' {
85
85
  namespace setImmediate {
86
86
  const __promisify__: typeof setImmediatePromise;
87
87
  }
88
- function clearImmediate(immediateId: NodeJS.Immediate): void;
88
+ function clearImmediate(immediateId: NodeJS.Immediate | undefined): void;
89
89
  function queueMicrotask(callback: () => void): void;
90
90
  }
91
91
  }
@@ -8,9 +8,9 @@ This package contains type definitions for Node.js (https://nodejs.org/).
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Sun, 01 May 2022 20:31:38 GMT
11
+ * Last updated: Thu, 19 May 2022 14:01:40 GMT
12
12
  * Dependencies: none
13
13
  * Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`, `structuredClone`
14
14
 
15
15
  # Credits
16
- These definitions were written by [Microsoft TypeScript](https://github.com/Microsoft), [DefinitelyTyped](https://github.com/DefinitelyTyped), [Alberto Schiabel](https://github.com/jkomyno), [Alvis HT Tang](https://github.com/alvis), [Andrew Makarov](https://github.com/r3nya), [Benjamin Toueg](https://github.com/btoueg), [Chigozirim C.](https://github.com/smac89), [David Junger](https://github.com/touffy), [Deividas Bakanas](https://github.com/DeividasBakanas), [Eugene Y. Q. Shen](https://github.com/eyqs), [Hannes Magnusson](https://github.com/Hannes-Magnusson-CK), [Huw](https://github.com/hoo29), [Kelvin Jin](https://github.com/kjin), [Klaus Meinhardt](https://github.com/ajafff), [Lishude](https://github.com/islishude), [Mariusz Wiktorczyk](https://github.com/mwiktorczyk), [Mohsen Azimi](https://github.com/mohsen1), [Nicolas Even](https://github.com/n-e), [Nikita Galkin](https://github.com/galkin), [Parambir Singh](https://github.com/parambirs), [Sebastian Silbermann](https://github.com/eps1lon), [Simon Schick](https://github.com/SimonSchick), [Thomas den Hollander](https://github.com/ThomasdenH), [Wilco Bakker](https://github.com/WilcoBakker), [wwwy3y3](https://github.com/wwwy3y3), [Samuel Ainsworth](https://github.com/samuela), [Kyle Uehlein](https://github.com/kuehlein), [Thanik Bhongbhibhat](https://github.com/bhongy), [Marcin Kopacz](https://github.com/chyzwar), [Trivikram Kamat](https://github.com/trivikr), [Junxiao Shi](https://github.com/yoursunny), [Ilia Baryshnikov](https://github.com/qwelias), [ExE Boss](https://github.com/ExE-Boss), [Piotr Błażejewicz](https://github.com/peterblazejewicz), [Anna Henningsen](https://github.com/addaleax), [Victor Perin](https://github.com/victorperin), [Yongsheng Zhang](https://github.com/ZYSzys), [NodeJS Contributors](https://github.com/NodeJS), [Linus Unnebäck](https://github.com/LinusU), and [wafuwafu13](https://github.com/wafuwafu13).
16
+ These definitions were written by [Microsoft TypeScript](https://github.com/Microsoft), [DefinitelyTyped](https://github.com/DefinitelyTyped), [Alberto Schiabel](https://github.com/jkomyno), [Alvis HT Tang](https://github.com/alvis), [Andrew Makarov](https://github.com/r3nya), [Benjamin Toueg](https://github.com/btoueg), [Chigozirim C.](https://github.com/smac89), [David Junger](https://github.com/touffy), [Deividas Bakanas](https://github.com/DeividasBakanas), [Eugene Y. Q. Shen](https://github.com/eyqs), [Hannes Magnusson](https://github.com/Hannes-Magnusson-CK), [Huw](https://github.com/hoo29), [Kelvin Jin](https://github.com/kjin), [Klaus Meinhardt](https://github.com/ajafff), [Lishude](https://github.com/islishude), [Mariusz Wiktorczyk](https://github.com/mwiktorczyk), [Mohsen Azimi](https://github.com/mohsen1), [Nicolas Even](https://github.com/n-e), [Nikita Galkin](https://github.com/galkin), [Parambir Singh](https://github.com/parambirs), [Sebastian Silbermann](https://github.com/eps1lon), [Simon Schick](https://github.com/SimonSchick), [Thomas den Hollander](https://github.com/ThomasdenH), [Wilco Bakker](https://github.com/WilcoBakker), [wwwy3y3](https://github.com/wwwy3y3), [Samuel Ainsworth](https://github.com/samuela), [Kyle Uehlein](https://github.com/kuehlein), [Thanik Bhongbhibhat](https://github.com/bhongy), [Marcin Kopacz](https://github.com/chyzwar), [Trivikram Kamat](https://github.com/trivikr), [Junxiao Shi](https://github.com/yoursunny), [Ilia Baryshnikov](https://github.com/qwelias), [ExE Boss](https://github.com/ExE-Boss), [Piotr Błażejewicz](https://github.com/peterblazejewicz), [Anna Henningsen](https://github.com/addaleax), [Victor Perin](https://github.com/victorperin), [Yongsheng Zhang](https://github.com/ZYSzys), [NodeJS Contributors](https://github.com/NodeJS), [Linus Unnebäck](https://github.com/LinusU), [wafuwafu13](https://github.com/wafuwafu13), and [Matteo Collina](https://github.com/mcollina).
@@ -40,6 +40,7 @@
40
40
  // NodeJS Contributors <https://github.com/NodeJS>
41
41
  // Linus Unnebäck <https://github.com/LinusU>
42
42
  // wafuwafu13 <https://github.com/wafuwafu13>
43
+ // Matteo Collina <https://github.com/mcollina>
43
44
  // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
44
45
 
45
46
  /**
@@ -285,6 +285,11 @@ declare module 'net' {
285
285
  * @since v0.5.10
286
286
  */
287
287
  readonly remotePort?: number | undefined;
288
+ /**
289
+ * The socket timeout in milliseconds as set by socket.setTimeout(). It is undefined if a timeout has not been set.
290
+ * @since v10.7.0
291
+ */
292
+ readonly timeout?: number | undefined;
288
293
  /**
289
294
  * Half-closes the socket. i.e., it sends a FIN packet. It is possible the
290
295
  * server will still send some data.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "17.0.31",
3
+ "version": "17.0.35",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -204,6 +204,11 @@
204
204
  "name": "wafuwafu13",
205
205
  "url": "https://github.com/wafuwafu13",
206
206
  "githubUsername": "wafuwafu13"
207
+ },
208
+ {
209
+ "name": "Matteo Collina",
210
+ "url": "https://github.com/mcollina",
211
+ "githubUsername": "mcollina"
207
212
  }
208
213
  ],
209
214
  "main": "",
@@ -215,6 +220,6 @@
215
220
  },
216
221
  "scripts": {},
217
222
  "dependencies": {},
218
- "typesPublisherContentHash": "187e51e75f3e87938751363254f337ef4fab9306b9bb5a7d36cb895b7c95c5e2",
223
+ "typesPublisherContentHash": "6238ccaa7b50cbe1d37bc66eabdea21a4bfb4a7fd6bd780350e84241e2810a00",
219
224
  "typeScriptVersion": "3.9"
220
225
  }
@@ -1238,6 +1238,19 @@ declare module 'stream' {
1238
1238
  ref(): void;
1239
1239
  unref(): void;
1240
1240
  }
1241
+
1242
+ /**
1243
+ * Returns whether the stream has encountered an error.
1244
+ * @since v17.3.0
1245
+ */
1246
+ function isErrored(stream: Readable | Writable | NodeJS.ReadableStream | NodeJS.WritableStream): boolean;
1247
+
1248
+ /**
1249
+ * Returns whether the stream is readable.
1250
+ * @since v17.4.0
1251
+ */
1252
+ function isReadable(stream: Readable | NodeJS.ReadableStream): boolean;
1253
+
1241
1254
  const promises: typeof streamPromises;
1242
1255
  const consumers: typeof streamConsumers;
1243
1256
  }
@@ -69,7 +69,7 @@ declare module 'timers' {
69
69
  namespace setTimeout {
70
70
  const __promisify__: typeof setTimeoutPromise;
71
71
  }
72
- function clearTimeout(timeoutId: NodeJS.Timeout): void;
72
+ function clearTimeout(timeoutId: NodeJS.Timeout | undefined): void;
73
73
  function setInterval<TArgs extends any[]>(callback: (...args: TArgs) => void, ms?: number, ...args: TArgs): NodeJS.Timer;
74
74
  // util.promisify no rest args compability
75
75
  // tslint:disable-next-line void-return
@@ -77,7 +77,7 @@ declare module 'timers' {
77
77
  namespace setInterval {
78
78
  const __promisify__: typeof setIntervalPromise;
79
79
  }
80
- function clearInterval(intervalId: NodeJS.Timeout): void;
80
+ function clearInterval(intervalId: NodeJS.Timeout | undefined): void;
81
81
  function setImmediate<TArgs extends any[]>(callback: (...args: TArgs) => void, ...args: TArgs): NodeJS.Immediate;
82
82
  // util.promisify no rest args compability
83
83
  // tslint:disable-next-line void-return
@@ -85,7 +85,7 @@ declare module 'timers' {
85
85
  namespace setImmediate {
86
86
  const __promisify__: typeof setImmediatePromise;
87
87
  }
88
- function clearImmediate(immediateId: NodeJS.Immediate): void;
88
+ function clearImmediate(immediateId: NodeJS.Immediate | undefined): void;
89
89
  function queueMicrotask(callback: () => void): void;
90
90
  }
91
91
  }
@@ -8,9 +8,9 @@ This package contains type definitions for Node.js (https://nodejs.org/).
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Sun, 01 May 2022 20:31:38 GMT
11
+ * Last updated: Thu, 19 May 2022 14:01:40 GMT
12
12
  * Dependencies: none
13
13
  * Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`, `structuredClone`
14
14
 
15
15
  # Credits
16
- These definitions were written by [Microsoft TypeScript](https://github.com/Microsoft), [DefinitelyTyped](https://github.com/DefinitelyTyped), [Alberto Schiabel](https://github.com/jkomyno), [Alvis HT Tang](https://github.com/alvis), [Andrew Makarov](https://github.com/r3nya), [Benjamin Toueg](https://github.com/btoueg), [Chigozirim C.](https://github.com/smac89), [David Junger](https://github.com/touffy), [Deividas Bakanas](https://github.com/DeividasBakanas), [Eugene Y. Q. Shen](https://github.com/eyqs), [Hannes Magnusson](https://github.com/Hannes-Magnusson-CK), [Huw](https://github.com/hoo29), [Kelvin Jin](https://github.com/kjin), [Klaus Meinhardt](https://github.com/ajafff), [Lishude](https://github.com/islishude), [Mariusz Wiktorczyk](https://github.com/mwiktorczyk), [Mohsen Azimi](https://github.com/mohsen1), [Nicolas Even](https://github.com/n-e), [Nikita Galkin](https://github.com/galkin), [Parambir Singh](https://github.com/parambirs), [Sebastian Silbermann](https://github.com/eps1lon), [Simon Schick](https://github.com/SimonSchick), [Thomas den Hollander](https://github.com/ThomasdenH), [Wilco Bakker](https://github.com/WilcoBakker), [wwwy3y3](https://github.com/wwwy3y3), [Samuel Ainsworth](https://github.com/samuela), [Kyle Uehlein](https://github.com/kuehlein), [Thanik Bhongbhibhat](https://github.com/bhongy), [Marcin Kopacz](https://github.com/chyzwar), [Trivikram Kamat](https://github.com/trivikr), [Junxiao Shi](https://github.com/yoursunny), [Ilia Baryshnikov](https://github.com/qwelias), [ExE Boss](https://github.com/ExE-Boss), [Piotr Błażejewicz](https://github.com/peterblazejewicz), [Anna Henningsen](https://github.com/addaleax), [Victor Perin](https://github.com/victorperin), [Yongsheng Zhang](https://github.com/ZYSzys), [NodeJS Contributors](https://github.com/NodeJS), [Linus Unnebäck](https://github.com/LinusU), and [wafuwafu13](https://github.com/wafuwafu13).
16
+ These definitions were written by [Microsoft TypeScript](https://github.com/Microsoft), [DefinitelyTyped](https://github.com/DefinitelyTyped), [Alberto Schiabel](https://github.com/jkomyno), [Alvis HT Tang](https://github.com/alvis), [Andrew Makarov](https://github.com/r3nya), [Benjamin Toueg](https://github.com/btoueg), [Chigozirim C.](https://github.com/smac89), [David Junger](https://github.com/touffy), [Deividas Bakanas](https://github.com/DeividasBakanas), [Eugene Y. Q. Shen](https://github.com/eyqs), [Hannes Magnusson](https://github.com/Hannes-Magnusson-CK), [Huw](https://github.com/hoo29), [Kelvin Jin](https://github.com/kjin), [Klaus Meinhardt](https://github.com/ajafff), [Lishude](https://github.com/islishude), [Mariusz Wiktorczyk](https://github.com/mwiktorczyk), [Mohsen Azimi](https://github.com/mohsen1), [Nicolas Even](https://github.com/n-e), [Nikita Galkin](https://github.com/galkin), [Parambir Singh](https://github.com/parambirs), [Sebastian Silbermann](https://github.com/eps1lon), [Simon Schick](https://github.com/SimonSchick), [Thomas den Hollander](https://github.com/ThomasdenH), [Wilco Bakker](https://github.com/WilcoBakker), [wwwy3y3](https://github.com/wwwy3y3), [Samuel Ainsworth](https://github.com/samuela), [Kyle Uehlein](https://github.com/kuehlein), [Thanik Bhongbhibhat](https://github.com/bhongy), [Marcin Kopacz](https://github.com/chyzwar), [Trivikram Kamat](https://github.com/trivikr), [Junxiao Shi](https://github.com/yoursunny), [Ilia Baryshnikov](https://github.com/qwelias), [ExE Boss](https://github.com/ExE-Boss), [Piotr Błażejewicz](https://github.com/peterblazejewicz), [Anna Henningsen](https://github.com/addaleax), [Victor Perin](https://github.com/victorperin), [Yongsheng Zhang](https://github.com/ZYSzys), [NodeJS Contributors](https://github.com/NodeJS), [Linus Unnebäck](https://github.com/LinusU), [wafuwafu13](https://github.com/wafuwafu13), and [Matteo Collina](https://github.com/mcollina).
@@ -40,6 +40,7 @@
40
40
  // NodeJS Contributors <https://github.com/NodeJS>
41
41
  // Linus Unnebäck <https://github.com/LinusU>
42
42
  // wafuwafu13 <https://github.com/wafuwafu13>
43
+ // Matteo Collina <https://github.com/mcollina>
43
44
  // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
44
45
 
45
46
  /**
@@ -285,6 +285,11 @@ declare module 'net' {
285
285
  * @since v0.5.10
286
286
  */
287
287
  readonly remotePort?: number | undefined;
288
+ /**
289
+ * The socket timeout in milliseconds as set by socket.setTimeout(). It is undefined if a timeout has not been set.
290
+ * @since v10.7.0
291
+ */
292
+ readonly timeout?: number | undefined;
288
293
  /**
289
294
  * Half-closes the socket. i.e., it sends a FIN packet. It is possible the
290
295
  * server will still send some data.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "17.0.31",
3
+ "version": "17.0.35",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -204,6 +204,11 @@
204
204
  "name": "wafuwafu13",
205
205
  "url": "https://github.com/wafuwafu13",
206
206
  "githubUsername": "wafuwafu13"
207
+ },
208
+ {
209
+ "name": "Matteo Collina",
210
+ "url": "https://github.com/mcollina",
211
+ "githubUsername": "mcollina"
207
212
  }
208
213
  ],
209
214
  "main": "",
@@ -215,6 +220,6 @@
215
220
  },
216
221
  "scripts": {},
217
222
  "dependencies": {},
218
- "typesPublisherContentHash": "187e51e75f3e87938751363254f337ef4fab9306b9bb5a7d36cb895b7c95c5e2",
223
+ "typesPublisherContentHash": "6238ccaa7b50cbe1d37bc66eabdea21a4bfb4a7fd6bd780350e84241e2810a00",
219
224
  "typeScriptVersion": "3.9"
220
225
  }
@@ -1238,6 +1238,19 @@ declare module 'stream' {
1238
1238
  ref(): void;
1239
1239
  unref(): void;
1240
1240
  }
1241
+
1242
+ /**
1243
+ * Returns whether the stream has encountered an error.
1244
+ * @since v17.3.0
1245
+ */
1246
+ function isErrored(stream: Readable | Writable | NodeJS.ReadableStream | NodeJS.WritableStream): boolean;
1247
+
1248
+ /**
1249
+ * Returns whether the stream is readable.
1250
+ * @since v17.4.0
1251
+ */
1252
+ function isReadable(stream: Readable | NodeJS.ReadableStream): boolean;
1253
+
1241
1254
  const promises: typeof streamPromises;
1242
1255
  const consumers: typeof streamConsumers;
1243
1256
  }
@@ -69,7 +69,7 @@ declare module 'timers' {
69
69
  namespace setTimeout {
70
70
  const __promisify__: typeof setTimeoutPromise;
71
71
  }
72
- function clearTimeout(timeoutId: NodeJS.Timeout): void;
72
+ function clearTimeout(timeoutId: NodeJS.Timeout | undefined): void;
73
73
  function setInterval<TArgs extends any[]>(callback: (...args: TArgs) => void, ms?: number, ...args: TArgs): NodeJS.Timer;
74
74
  // util.promisify no rest args compability
75
75
  // tslint:disable-next-line void-return
@@ -77,7 +77,7 @@ declare module 'timers' {
77
77
  namespace setInterval {
78
78
  const __promisify__: typeof setIntervalPromise;
79
79
  }
80
- function clearInterval(intervalId: NodeJS.Timeout): void;
80
+ function clearInterval(intervalId: NodeJS.Timeout | undefined): void;
81
81
  function setImmediate<TArgs extends any[]>(callback: (...args: TArgs) => void, ...args: TArgs): NodeJS.Immediate;
82
82
  // util.promisify no rest args compability
83
83
  // tslint:disable-next-line void-return
@@ -85,7 +85,7 @@ declare module 'timers' {
85
85
  namespace setImmediate {
86
86
  const __promisify__: typeof setImmediatePromise;
87
87
  }
88
- function clearImmediate(immediateId: NodeJS.Immediate): void;
88
+ function clearImmediate(immediateId: NodeJS.Immediate | undefined): void;
89
89
  function queueMicrotask(callback: () => void): void;
90
90
  }
91
91
  }
@@ -8,9 +8,9 @@ This package contains type definitions for Node.js (https://nodejs.org/).
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Sun, 01 May 2022 20:31:38 GMT
11
+ * Last updated: Thu, 19 May 2022 14:01:40 GMT
12
12
  * Dependencies: none
13
13
  * Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`, `structuredClone`
14
14
 
15
15
  # Credits
16
- These definitions were written by [Microsoft TypeScript](https://github.com/Microsoft), [DefinitelyTyped](https://github.com/DefinitelyTyped), [Alberto Schiabel](https://github.com/jkomyno), [Alvis HT Tang](https://github.com/alvis), [Andrew Makarov](https://github.com/r3nya), [Benjamin Toueg](https://github.com/btoueg), [Chigozirim C.](https://github.com/smac89), [David Junger](https://github.com/touffy), [Deividas Bakanas](https://github.com/DeividasBakanas), [Eugene Y. Q. Shen](https://github.com/eyqs), [Hannes Magnusson](https://github.com/Hannes-Magnusson-CK), [Huw](https://github.com/hoo29), [Kelvin Jin](https://github.com/kjin), [Klaus Meinhardt](https://github.com/ajafff), [Lishude](https://github.com/islishude), [Mariusz Wiktorczyk](https://github.com/mwiktorczyk), [Mohsen Azimi](https://github.com/mohsen1), [Nicolas Even](https://github.com/n-e), [Nikita Galkin](https://github.com/galkin), [Parambir Singh](https://github.com/parambirs), [Sebastian Silbermann](https://github.com/eps1lon), [Simon Schick](https://github.com/SimonSchick), [Thomas den Hollander](https://github.com/ThomasdenH), [Wilco Bakker](https://github.com/WilcoBakker), [wwwy3y3](https://github.com/wwwy3y3), [Samuel Ainsworth](https://github.com/samuela), [Kyle Uehlein](https://github.com/kuehlein), [Thanik Bhongbhibhat](https://github.com/bhongy), [Marcin Kopacz](https://github.com/chyzwar), [Trivikram Kamat](https://github.com/trivikr), [Junxiao Shi](https://github.com/yoursunny), [Ilia Baryshnikov](https://github.com/qwelias), [ExE Boss](https://github.com/ExE-Boss), [Piotr Błażejewicz](https://github.com/peterblazejewicz), [Anna Henningsen](https://github.com/addaleax), [Victor Perin](https://github.com/victorperin), [Yongsheng Zhang](https://github.com/ZYSzys), [NodeJS Contributors](https://github.com/NodeJS), [Linus Unnebäck](https://github.com/LinusU), and [wafuwafu13](https://github.com/wafuwafu13).
16
+ These definitions were written by [Microsoft TypeScript](https://github.com/Microsoft), [DefinitelyTyped](https://github.com/DefinitelyTyped), [Alberto Schiabel](https://github.com/jkomyno), [Alvis HT Tang](https://github.com/alvis), [Andrew Makarov](https://github.com/r3nya), [Benjamin Toueg](https://github.com/btoueg), [Chigozirim C.](https://github.com/smac89), [David Junger](https://github.com/touffy), [Deividas Bakanas](https://github.com/DeividasBakanas), [Eugene Y. Q. Shen](https://github.com/eyqs), [Hannes Magnusson](https://github.com/Hannes-Magnusson-CK), [Huw](https://github.com/hoo29), [Kelvin Jin](https://github.com/kjin), [Klaus Meinhardt](https://github.com/ajafff), [Lishude](https://github.com/islishude), [Mariusz Wiktorczyk](https://github.com/mwiktorczyk), [Mohsen Azimi](https://github.com/mohsen1), [Nicolas Even](https://github.com/n-e), [Nikita Galkin](https://github.com/galkin), [Parambir Singh](https://github.com/parambirs), [Sebastian Silbermann](https://github.com/eps1lon), [Simon Schick](https://github.com/SimonSchick), [Thomas den Hollander](https://github.com/ThomasdenH), [Wilco Bakker](https://github.com/WilcoBakker), [wwwy3y3](https://github.com/wwwy3y3), [Samuel Ainsworth](https://github.com/samuela), [Kyle Uehlein](https://github.com/kuehlein), [Thanik Bhongbhibhat](https://github.com/bhongy), [Marcin Kopacz](https://github.com/chyzwar), [Trivikram Kamat](https://github.com/trivikr), [Junxiao Shi](https://github.com/yoursunny), [Ilia Baryshnikov](https://github.com/qwelias), [ExE Boss](https://github.com/ExE-Boss), [Piotr Błażejewicz](https://github.com/peterblazejewicz), [Anna Henningsen](https://github.com/addaleax), [Victor Perin](https://github.com/victorperin), [Yongsheng Zhang](https://github.com/ZYSzys), [NodeJS Contributors](https://github.com/NodeJS), [Linus Unnebäck](https://github.com/LinusU), [wafuwafu13](https://github.com/wafuwafu13), and [Matteo Collina](https://github.com/mcollina).
@@ -40,6 +40,7 @@
40
40
  // NodeJS Contributors <https://github.com/NodeJS>
41
41
  // Linus Unnebäck <https://github.com/LinusU>
42
42
  // wafuwafu13 <https://github.com/wafuwafu13>
43
+ // Matteo Collina <https://github.com/mcollina>
43
44
  // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
44
45
 
45
46
  /**
@@ -285,6 +285,11 @@ declare module 'net' {
285
285
  * @since v0.5.10
286
286
  */
287
287
  readonly remotePort?: number | undefined;
288
+ /**
289
+ * The socket timeout in milliseconds as set by socket.setTimeout(). It is undefined if a timeout has not been set.
290
+ * @since v10.7.0
291
+ */
292
+ readonly timeout?: number | undefined;
288
293
  /**
289
294
  * Half-closes the socket. i.e., it sends a FIN packet. It is possible the
290
295
  * server will still send some data.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "17.0.31",
3
+ "version": "17.0.35",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -204,6 +204,11 @@
204
204
  "name": "wafuwafu13",
205
205
  "url": "https://github.com/wafuwafu13",
206
206
  "githubUsername": "wafuwafu13"
207
+ },
208
+ {
209
+ "name": "Matteo Collina",
210
+ "url": "https://github.com/mcollina",
211
+ "githubUsername": "mcollina"
207
212
  }
208
213
  ],
209
214
  "main": "",
@@ -215,6 +220,6 @@
215
220
  },
216
221
  "scripts": {},
217
222
  "dependencies": {},
218
- "typesPublisherContentHash": "187e51e75f3e87938751363254f337ef4fab9306b9bb5a7d36cb895b7c95c5e2",
223
+ "typesPublisherContentHash": "6238ccaa7b50cbe1d37bc66eabdea21a4bfb4a7fd6bd780350e84241e2810a00",
219
224
  "typeScriptVersion": "3.9"
220
225
  }
@@ -1238,6 +1238,19 @@ declare module 'stream' {
1238
1238
  ref(): void;
1239
1239
  unref(): void;
1240
1240
  }
1241
+
1242
+ /**
1243
+ * Returns whether the stream has encountered an error.
1244
+ * @since v17.3.0
1245
+ */
1246
+ function isErrored(stream: Readable | Writable | NodeJS.ReadableStream | NodeJS.WritableStream): boolean;
1247
+
1248
+ /**
1249
+ * Returns whether the stream is readable.
1250
+ * @since v17.4.0
1251
+ */
1252
+ function isReadable(stream: Readable | NodeJS.ReadableStream): boolean;
1253
+
1241
1254
  const promises: typeof streamPromises;
1242
1255
  const consumers: typeof streamConsumers;
1243
1256
  }
@@ -69,7 +69,7 @@ declare module 'timers' {
69
69
  namespace setTimeout {
70
70
  const __promisify__: typeof setTimeoutPromise;
71
71
  }
72
- function clearTimeout(timeoutId: NodeJS.Timeout): void;
72
+ function clearTimeout(timeoutId: NodeJS.Timeout | undefined): void;
73
73
  function setInterval<TArgs extends any[]>(callback: (...args: TArgs) => void, ms?: number, ...args: TArgs): NodeJS.Timer;
74
74
  // util.promisify no rest args compability
75
75
  // tslint:disable-next-line void-return
@@ -77,7 +77,7 @@ declare module 'timers' {
77
77
  namespace setInterval {
78
78
  const __promisify__: typeof setIntervalPromise;
79
79
  }
80
- function clearInterval(intervalId: NodeJS.Timeout): void;
80
+ function clearInterval(intervalId: NodeJS.Timeout | undefined): void;
81
81
  function setImmediate<TArgs extends any[]>(callback: (...args: TArgs) => void, ...args: TArgs): NodeJS.Immediate;
82
82
  // util.promisify no rest args compability
83
83
  // tslint:disable-next-line void-return
@@ -85,7 +85,7 @@ declare module 'timers' {
85
85
  namespace setImmediate {
86
86
  const __promisify__: typeof setImmediatePromise;
87
87
  }
88
- function clearImmediate(immediateId: NodeJS.Immediate): void;
88
+ function clearImmediate(immediateId: NodeJS.Immediate | undefined): void;
89
89
  function queueMicrotask(callback: () => void): void;
90
90
  }
91
91
  }
@@ -8,9 +8,9 @@ This package contains type definitions for Node.js (https://nodejs.org/).
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Sun, 01 May 2022 20:31:38 GMT
11
+ * Last updated: Thu, 19 May 2022 14:01:40 GMT
12
12
  * Dependencies: none
13
13
  * Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`, `structuredClone`
14
14
 
15
15
  # Credits
16
- These definitions were written by [Microsoft TypeScript](https://github.com/Microsoft), [DefinitelyTyped](https://github.com/DefinitelyTyped), [Alberto Schiabel](https://github.com/jkomyno), [Alvis HT Tang](https://github.com/alvis), [Andrew Makarov](https://github.com/r3nya), [Benjamin Toueg](https://github.com/btoueg), [Chigozirim C.](https://github.com/smac89), [David Junger](https://github.com/touffy), [Deividas Bakanas](https://github.com/DeividasBakanas), [Eugene Y. Q. Shen](https://github.com/eyqs), [Hannes Magnusson](https://github.com/Hannes-Magnusson-CK), [Huw](https://github.com/hoo29), [Kelvin Jin](https://github.com/kjin), [Klaus Meinhardt](https://github.com/ajafff), [Lishude](https://github.com/islishude), [Mariusz Wiktorczyk](https://github.com/mwiktorczyk), [Mohsen Azimi](https://github.com/mohsen1), [Nicolas Even](https://github.com/n-e), [Nikita Galkin](https://github.com/galkin), [Parambir Singh](https://github.com/parambirs), [Sebastian Silbermann](https://github.com/eps1lon), [Simon Schick](https://github.com/SimonSchick), [Thomas den Hollander](https://github.com/ThomasdenH), [Wilco Bakker](https://github.com/WilcoBakker), [wwwy3y3](https://github.com/wwwy3y3), [Samuel Ainsworth](https://github.com/samuela), [Kyle Uehlein](https://github.com/kuehlein), [Thanik Bhongbhibhat](https://github.com/bhongy), [Marcin Kopacz](https://github.com/chyzwar), [Trivikram Kamat](https://github.com/trivikr), [Junxiao Shi](https://github.com/yoursunny), [Ilia Baryshnikov](https://github.com/qwelias), [ExE Boss](https://github.com/ExE-Boss), [Piotr Błażejewicz](https://github.com/peterblazejewicz), [Anna Henningsen](https://github.com/addaleax), [Victor Perin](https://github.com/victorperin), [Yongsheng Zhang](https://github.com/ZYSzys), [NodeJS Contributors](https://github.com/NodeJS), [Linus Unnebäck](https://github.com/LinusU), and [wafuwafu13](https://github.com/wafuwafu13).
16
+ These definitions were written by [Microsoft TypeScript](https://github.com/Microsoft), [DefinitelyTyped](https://github.com/DefinitelyTyped), [Alberto Schiabel](https://github.com/jkomyno), [Alvis HT Tang](https://github.com/alvis), [Andrew Makarov](https://github.com/r3nya), [Benjamin Toueg](https://github.com/btoueg), [Chigozirim C.](https://github.com/smac89), [David Junger](https://github.com/touffy), [Deividas Bakanas](https://github.com/DeividasBakanas), [Eugene Y. Q. Shen](https://github.com/eyqs), [Hannes Magnusson](https://github.com/Hannes-Magnusson-CK), [Huw](https://github.com/hoo29), [Kelvin Jin](https://github.com/kjin), [Klaus Meinhardt](https://github.com/ajafff), [Lishude](https://github.com/islishude), [Mariusz Wiktorczyk](https://github.com/mwiktorczyk), [Mohsen Azimi](https://github.com/mohsen1), [Nicolas Even](https://github.com/n-e), [Nikita Galkin](https://github.com/galkin), [Parambir Singh](https://github.com/parambirs), [Sebastian Silbermann](https://github.com/eps1lon), [Simon Schick](https://github.com/SimonSchick), [Thomas den Hollander](https://github.com/ThomasdenH), [Wilco Bakker](https://github.com/WilcoBakker), [wwwy3y3](https://github.com/wwwy3y3), [Samuel Ainsworth](https://github.com/samuela), [Kyle Uehlein](https://github.com/kuehlein), [Thanik Bhongbhibhat](https://github.com/bhongy), [Marcin Kopacz](https://github.com/chyzwar), [Trivikram Kamat](https://github.com/trivikr), [Junxiao Shi](https://github.com/yoursunny), [Ilia Baryshnikov](https://github.com/qwelias), [ExE Boss](https://github.com/ExE-Boss), [Piotr Błażejewicz](https://github.com/peterblazejewicz), [Anna Henningsen](https://github.com/addaleax), [Victor Perin](https://github.com/victorperin), [Yongsheng Zhang](https://github.com/ZYSzys), [NodeJS Contributors](https://github.com/NodeJS), [Linus Unnebäck](https://github.com/LinusU), [wafuwafu13](https://github.com/wafuwafu13), and [Matteo Collina](https://github.com/mcollina).
@@ -40,6 +40,7 @@
40
40
  // NodeJS Contributors <https://github.com/NodeJS>
41
41
  // Linus Unnebäck <https://github.com/LinusU>
42
42
  // wafuwafu13 <https://github.com/wafuwafu13>
43
+ // Matteo Collina <https://github.com/mcollina>
43
44
  // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
44
45
 
45
46
  /**
@@ -285,6 +285,11 @@ declare module 'net' {
285
285
  * @since v0.5.10
286
286
  */
287
287
  readonly remotePort?: number | undefined;
288
+ /**
289
+ * The socket timeout in milliseconds as set by socket.setTimeout(). It is undefined if a timeout has not been set.
290
+ * @since v10.7.0
291
+ */
292
+ readonly timeout?: number | undefined;
288
293
  /**
289
294
  * Half-closes the socket. i.e., it sends a FIN packet. It is possible the
290
295
  * server will still send some data.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "17.0.31",
3
+ "version": "17.0.35",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -204,6 +204,11 @@
204
204
  "name": "wafuwafu13",
205
205
  "url": "https://github.com/wafuwafu13",
206
206
  "githubUsername": "wafuwafu13"
207
+ },
208
+ {
209
+ "name": "Matteo Collina",
210
+ "url": "https://github.com/mcollina",
211
+ "githubUsername": "mcollina"
207
212
  }
208
213
  ],
209
214
  "main": "",
@@ -215,6 +220,6 @@
215
220
  },
216
221
  "scripts": {},
217
222
  "dependencies": {},
218
- "typesPublisherContentHash": "187e51e75f3e87938751363254f337ef4fab9306b9bb5a7d36cb895b7c95c5e2",
223
+ "typesPublisherContentHash": "6238ccaa7b50cbe1d37bc66eabdea21a4bfb4a7fd6bd780350e84241e2810a00",
219
224
  "typeScriptVersion": "3.9"
220
225
  }
@@ -1238,6 +1238,19 @@ declare module 'stream' {
1238
1238
  ref(): void;
1239
1239
  unref(): void;
1240
1240
  }
1241
+
1242
+ /**
1243
+ * Returns whether the stream has encountered an error.
1244
+ * @since v17.3.0
1245
+ */
1246
+ function isErrored(stream: Readable | Writable | NodeJS.ReadableStream | NodeJS.WritableStream): boolean;
1247
+
1248
+ /**
1249
+ * Returns whether the stream is readable.
1250
+ * @since v17.4.0
1251
+ */
1252
+ function isReadable(stream: Readable | NodeJS.ReadableStream): boolean;
1253
+
1241
1254
  const promises: typeof streamPromises;
1242
1255
  const consumers: typeof streamConsumers;
1243
1256
  }
@@ -69,7 +69,7 @@ declare module 'timers' {
69
69
  namespace setTimeout {
70
70
  const __promisify__: typeof setTimeoutPromise;
71
71
  }
72
- function clearTimeout(timeoutId: NodeJS.Timeout): void;
72
+ function clearTimeout(timeoutId: NodeJS.Timeout | undefined): void;
73
73
  function setInterval<TArgs extends any[]>(callback: (...args: TArgs) => void, ms?: number, ...args: TArgs): NodeJS.Timer;
74
74
  // util.promisify no rest args compability
75
75
  // tslint:disable-next-line void-return
@@ -77,7 +77,7 @@ declare module 'timers' {
77
77
  namespace setInterval {
78
78
  const __promisify__: typeof setIntervalPromise;
79
79
  }
80
- function clearInterval(intervalId: NodeJS.Timeout): void;
80
+ function clearInterval(intervalId: NodeJS.Timeout | undefined): void;
81
81
  function setImmediate<TArgs extends any[]>(callback: (...args: TArgs) => void, ...args: TArgs): NodeJS.Immediate;
82
82
  // util.promisify no rest args compability
83
83
  // tslint:disable-next-line void-return
@@ -85,7 +85,7 @@ declare module 'timers' {
85
85
  namespace setImmediate {
86
86
  const __promisify__: typeof setImmediatePromise;
87
87
  }
88
- function clearImmediate(immediateId: NodeJS.Immediate): void;
88
+ function clearImmediate(immediateId: NodeJS.Immediate | undefined): void;
89
89
  function queueMicrotask(callback: () => void): void;
90
90
  }
91
91
  }
@@ -274,21 +274,26 @@ RedirectableRequest.prototype._performRequest = function () {
274
274
  this._options.agent = this._options.agents[scheme];
275
275
  }
276
276
 
277
- // Create the native request
277
+ // Create the native request and set up its event handlers
278
278
  var request = this._currentRequest =
279
279
  nativeProtocol.request(this._options, this._onNativeResponse);
280
- this._currentUrl = url.format(this._options);
281
-
282
- // Set up event handlers
283
280
  request._redirectable = this;
284
- for (var e = 0; e < events.length; e++) {
285
- request.on(events[e], eventHandlers[events[e]]);
281
+ for (var event of events) {
282
+ request.on(event, eventHandlers[event]);
286
283
  }
287
284
 
285
+ // RFC7230§5.3.1: When making a request directly to an origin server, […]
286
+ // a client MUST send only the absolute path […] as the request-target.
287
+ this._currentUrl = /^\//.test(this._options.path) ?
288
+ url.format(this._options) :
289
+ // When making a request to a proxy, […]
290
+ // a client MUST send the target URI in absolute-form […].
291
+ this._currentUrl = this._options.path;
292
+
288
293
  // End a redirected request
289
294
  // (The first request must be ended explicitly with RedirectableRequest#end)
290
295
  if (this._isRedirect) {
291
- // Write the request entity and end.
296
+ // Write the request entity and end
292
297
  var i = 0;
293
298
  var self = this;
294
299
  var buffers = this._requestBodyBuffers;
@@ -576,8 +581,8 @@ function createErrorType(code, defaultMessage) {
576
581
  }
577
582
 
578
583
  function abortRequest(request) {
579
- for (var e = 0; e < events.length; e++) {
580
- request.removeListener(events[e], eventHandlers[events[e]]);
584
+ for (var event of events) {
585
+ request.removeListener(event, eventHandlers[event]);
581
586
  }
582
587
  request.on("error", noop);
583
588
  request.abort();
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "follow-redirects",
3
- "version": "1.15.0",
3
+ "version": "1.15.1",
4
4
  "description": "HTTP and HTTPS modules that follow redirects.",
5
5
  "license": "MIT",
6
6
  "main": "index.js",
@@ -113,11 +113,11 @@ function asPromise(normalizedOptions) {
113
113
  request._beforeError(new types_1.RequestError(error.message, error, request));
114
114
  return;
115
115
  }
116
+ globalResponse = response;
116
117
  if (!is_response_ok_1.isResponseOk(response)) {
117
118
  request._beforeError(new types_1.HTTPError(response));
118
119
  return;
119
120
  }
120
- globalResponse = response;
121
121
  resolve(request.options.resolveBodyOnly ? response.body : response);
122
122
  });
123
123
  const onError = (error) => {
@@ -866,6 +866,14 @@ class Request extends stream_1.Duplex {
866
866
  const redirectUrl = new url_1.URL(redirectBuffer, url);
867
867
  const redirectString = redirectUrl.toString();
868
868
  decodeURI(redirectString);
869
+ // eslint-disable-next-line no-inner-declarations
870
+ function isUnixSocketURL(url) {
871
+ return url.protocol === 'unix:' || url.hostname === 'unix';
872
+ }
873
+ if (!isUnixSocketURL(url) && isUnixSocketURL(redirectUrl)) {
874
+ this._beforeError(new RequestError('Cannot redirect to UNIX socket', {}, this));
875
+ return;
876
+ }
869
877
  // Redirecting to a different site, clear sensitive data.
870
878
  if (redirectUrl.hostname !== url.hostname || redirectUrl.port !== url.port) {
871
879
  if ('host' in options.headers) {