Skip to content
This repository was archived by the owner on Feb 12, 2024. It is now read-only.

Commit 516505b

Browse files
authored
chore: update native-abort-controller module (#3521)
To avoid extending built-in classes you now need to use named exports when importing `native-abort-controller`. Fixes #3509
1 parent 95b891f commit 516505b

File tree

25 files changed

+78
-53
lines changed

25 files changed

+78
-53
lines changed

examples/browser-ipns-publish/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
"human-crypto-keys": "^0.1.4",
1616
"ipfs": "^0.54.1",
1717
"ipfs-http-client": "^49.0.1",
18-
"ipfs-utils": "^6.0.0",
18+
"ipfs-utils": "^6.0.1",
1919
"ipns": "^0.8.0",
2020
"it-last": "^1.0.4",
2121
"p-retry": "^4.2.0",

packages/interface-ipfs-core/package.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
"scripts": {
1616
"lint": "aegir lint",
1717
"test": "echo 'No tests here'",
18-
"dep-check": "aegir dep-check"
18+
"dep-check": "aegir dep-check -i abort-controller"
1919
},
2020
"files": [
2121
"src/",
@@ -30,6 +30,7 @@
3030
],
3131
"license": "MIT",
3232
"dependencies": {
33+
"abort-controller": "^3.0.0",
3334
"aegir": "^30.3.0",
3435
"chai": "^4.2.0",
3536
"chai-as-promised": "^7.1.1",
@@ -40,7 +41,7 @@
4041
"err-code": "^2.0.3",
4142
"ipfs-unixfs": "^2.0.3",
4243
"ipfs-unixfs-importer": "^5.0.0",
43-
"ipfs-utils": "^6.0.0",
44+
"ipfs-utils": "^6.0.1",
4445
"ipld-block": "^0.11.0",
4546
"ipld-dag-cbor": "^0.17.0",
4647
"ipld-dag-pb": "^0.20.0",
@@ -61,7 +62,7 @@
6162
"multibase": "^3.0.0",
6263
"multihashing-async": "^2.0.1",
6364
"nanoid": "^3.1.12",
64-
"native-abort-controller": "~0.0.3",
65+
"native-abort-controller": "^1.0.3",
6566
"p-map": "^4.0.0",
6667
"peer-id": "^0.14.1",
6768
"readable-stream": "^3.4.0",

packages/interface-ipfs-core/src/bitswap/wantlist.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ const { getDescribe, getIt, expect } = require('../utils/mocha')
55
const { waitForWantlistKey, waitForWantlistKeyToBeRemoved } = require('./utils')
66
const { isWebWorker } = require('ipfs-utils/src/env')
77
const testTimeout = require('../utils/test-timeout')
8-
const AbortController = require('native-abort-controller')
8+
const { AbortController } = require('native-abort-controller')
99
const CID = require('cids')
1010
const delay = require('delay')
1111
const getIpfsOptions = require('../utils/ipfs-options-websockets-filter-all')

packages/interface-ipfs-core/src/pubsub/subscribe.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ const all = require('it-all')
99
const { waitForPeers, getTopic } = require('./utils')
1010
const { getDescribe, getIt, expect } = require('../utils/mocha')
1111
const delay = require('delay')
12-
const AbortController = require('native-abort-controller')
12+
const { AbortController } = require('native-abort-controller')
1313
const { isWebWorker, isNode } = require('ipfs-utils/src/env')
1414
const getIpfsOptions = require('../utils/ipfs-options-websockets-filter-all')
1515
const first = require('it-first')

packages/ipfs-cli/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
"ipfs-daemon": "^0.5.1",
4242
"ipfs-http-client": "^49.0.1",
4343
"ipfs-repo": "^8.0.0",
44-
"ipfs-utils": "^6.0.0",
44+
"ipfs-utils": "^6.0.1",
4545
"ipld-dag-cbor": "^0.17.0",
4646
"ipld-dag-pb": "^0.20.0",
4747
"it-all": "^1.0.4",

packages/ipfs-core-utils/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,13 @@
3636
},
3737
"license": "MIT",
3838
"dependencies": {
39-
"any-signal": "^2.0.0",
39+
"any-signal": "^2.1.2",
4040
"blob-to-it": "^1.0.1",
4141
"browser-readablestream-to-it": "^1.0.1",
4242
"cids": "^1.1.5",
4343
"err-code": "^2.0.3",
4444
"ipfs-core-types": "^0.3.0",
45-
"ipfs-utils": "^6.0.0",
45+
"ipfs-utils": "^6.0.1",
4646
"it-all": "^1.0.4",
4747
"it-map": "^1.0.4",
4848
"it-peekable": "^1.0.1",

packages/ipfs-core/package.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,10 @@
5050
"test:bootstrapers": "IPFS_TEST=bootstrapers aegir test -t browser -f test/bootstrapers.js",
5151
"coverage": "nyc --reporter=text --reporter=lcov npm run test:node",
5252
"clean": "rimraf ./dist",
53-
"dep-check": "aegir dep-check -i interface-ipfs-core -i ipfs-core-types"
53+
"dep-check": "aegir dep-check -i interface-ipfs-core -i ipfs-core-types -i abort-controller"
5454
},
5555
"dependencies": {
56+
"abort-controller": "^3.0.0",
5657
"array-shuffle": "^2.0.0",
5758
"bignumber.js": "^9.0.0",
5859
"cbor": "^6.0.1",
@@ -75,7 +76,7 @@
7576
"ipfs-unixfs": "^2.0.3",
7677
"ipfs-unixfs-exporter": "^3.0.4",
7778
"ipfs-unixfs-importer": "^5.0.0",
78-
"ipfs-utils": "^6.0.0",
79+
"ipfs-utils": "^6.0.1",
7980
"ipld": "^0.28.0",
8081
"ipld-block": "^0.11.0",
8182
"ipld-dag-cbor": "^0.17.0",
@@ -109,7 +110,7 @@
109110
"multibase": "^3.0.0",
110111
"multicodec": "^2.0.1",
111112
"multihashing-async": "^2.0.1",
112-
"native-abort-controller": "~0.0.3",
113+
"native-abort-controller": "^1.0.3",
113114
"p-queue": "^6.6.1",
114115
"parse-duration": "^0.4.4",
115116
"peer-id": "^0.14.1",

packages/ipfs-core/src/preload.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ const toUri = require('multiaddr-to-uri')
44
const debug = require('debug')
55
const CID = require('cids')
66
const shuffle = require('array-shuffle')
7-
const AbortController = require('native-abort-controller')
7+
const { AbortController } = require('native-abort-controller')
88
const preload = require('./runtime/preload-nodejs')
99
/** @type {typeof import('hashlru').default} */
1010
// @ts-ignore - hashlru has incorrect typedefs

packages/ipfs-daemon/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
"ipfs-http-client": "^49.0.1",
3636
"ipfs-http-gateway": "^0.3.0",
3737
"ipfs-http-server": "^0.3.1",
38-
"ipfs-utils": "^6.0.0",
38+
"ipfs-utils": "^6.0.1",
3939
"just-safe-set": "^2.1.0",
4040
"libp2p": "^0.30.7",
4141
"libp2p-delegated-content-routing": "^0.9.0",

packages/ipfs-http-client/package.json

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,17 +48,18 @@
4848
"prepare": "aegir build --no-bundle",
4949
"coverage": "npx nyc -r html npm run test:node -- --bail",
5050
"clean": "rimraf ./dist",
51-
"dep-check": "aegir dep-check -i ipfs-core -i rimraf -i ipfs-core-types"
51+
"dep-check": "aegir dep-check -i ipfs-core -i rimraf -i ipfs-core-types -i abort-controller"
5252
},
5353
"dependencies": {
54-
"any-signal": "^2.0.0",
54+
"abort-controller": "^3.0.0",
55+
"any-signal": "^2.1.2",
5556
"bignumber.js": "^9.0.0",
5657
"cids": "^1.1.5",
5758
"debug": "^4.1.1",
5859
"form-data": "^3.0.0",
5960
"ipfs-core-types": "^0.3.0",
6061
"ipfs-core-utils": "^0.7.0",
61-
"ipfs-utils": "^6.0.0",
62+
"ipfs-utils": "^6.0.1",
6263
"ipld-block": "^0.11.0",
6364
"ipld-dag-cbor": "^0.17.0",
6465
"ipld-dag-pb": "^0.20.0",
@@ -73,7 +74,7 @@
7374
"multicodec": "^2.0.1",
7475
"multihashes": "^3.0.1",
7576
"nanoid": "^3.1.12",
76-
"native-abort-controller": "~0.0.3",
77+
"native-abort-controller": "^1.0.3",
7778
"parse-duration": "^0.4.4",
7879
"stream-to-it": "^0.2.2",
7980
"uint8arrays": "^2.0.5"

0 commit comments

Comments
 (0)