Skip to content

Commit d07db37

Browse files
authored
deps!: update multiformats to 10.x.x and all @ipld/* deps (#425)
Updates to new versions of multiformats and `@ipld` deps
1 parent 0bb4ed7 commit d07db37

File tree

12 files changed

+82
-90
lines changed

12 files changed

+82
-90
lines changed

.github/workflows/js-test-and-release.yml

+19-19
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ jobs:
1212
check:
1313
runs-on: ubuntu-latest
1414
steps:
15-
- uses: actions/checkout@v2
16-
- uses: actions/setup-node@v2
15+
- uses: actions/checkout@v3
16+
- uses: actions/setup-node@v3
1717
with:
1818
node-version: lts/*
1919
- uses: ipfs/aegir/actions/cache-node-modules@master
@@ -25,12 +25,12 @@ jobs:
2525
runs-on: ${{ matrix.os }}
2626
strategy:
2727
matrix:
28-
os: [ubuntu-latest, macos-latest]
28+
os: [windows-latest, ubuntu-latest, macos-latest]
2929
node: [16]
3030
fail-fast: true
3131
steps:
32-
- uses: actions/checkout@v2
33-
- uses: actions/setup-node@v2
32+
- uses: actions/checkout@v3
33+
- uses: actions/setup-node@v3
3434
with:
3535
node-version: ${{ matrix.node }}
3636
- uses: ipfs/aegir/actions/cache-node-modules@master
@@ -43,8 +43,8 @@ jobs:
4343
needs: check
4444
runs-on: ubuntu-latest
4545
steps:
46-
- uses: actions/checkout@v2
47-
- uses: actions/setup-node@v2
46+
- uses: actions/checkout@v3
47+
- uses: actions/setup-node@v3
4848
with:
4949
node-version: lts/*
5050
- uses: ipfs/aegir/actions/cache-node-modules@master
@@ -57,8 +57,8 @@ jobs:
5757
needs: check
5858
runs-on: ubuntu-latest
5959
steps:
60-
- uses: actions/checkout@v2
61-
- uses: actions/setup-node@v2
60+
- uses: actions/checkout@v3
61+
- uses: actions/setup-node@v3
6262
with:
6363
node-version: lts/*
6464
- uses: ipfs/aegir/actions/cache-node-modules@master
@@ -71,8 +71,8 @@ jobs:
7171
needs: check
7272
runs-on: ubuntu-latest
7373
steps:
74-
- uses: actions/checkout@v2
75-
- uses: actions/setup-node@v2
74+
- uses: actions/checkout@v3
75+
- uses: actions/setup-node@v3
7676
with:
7777
node-version: lts/*
7878
- uses: ipfs/aegir/actions/cache-node-modules@master
@@ -85,8 +85,8 @@ jobs:
8585
needs: check
8686
runs-on: ubuntu-latest
8787
steps:
88-
- uses: actions/checkout@v2
89-
- uses: actions/setup-node@v2
88+
- uses: actions/checkout@v3
89+
- uses: actions/setup-node@v3
9090
with:
9191
node-version: lts/*
9292
- uses: ipfs/aegir/actions/cache-node-modules@master
@@ -99,8 +99,8 @@ jobs:
9999
needs: check
100100
runs-on: ubuntu-latest
101101
steps:
102-
- uses: actions/checkout@v2
103-
- uses: actions/setup-node@v2
102+
- uses: actions/checkout@v3
103+
- uses: actions/setup-node@v3
104104
with:
105105
node-version: lts/*
106106
- uses: ipfs/aegir/actions/cache-node-modules@master
@@ -113,8 +113,8 @@ jobs:
113113
needs: check
114114
runs-on: ubuntu-latest
115115
steps:
116-
- uses: actions/checkout@v2
117-
- uses: actions/setup-node@v2
116+
- uses: actions/checkout@v3
117+
- uses: actions/setup-node@v3
118118
with:
119119
node-version: lts/*
120120
- uses: ipfs/aegir/actions/cache-node-modules@master
@@ -128,10 +128,10 @@ jobs:
128128
runs-on: ubuntu-latest
129129
if: github.event_name == 'push' && github.ref == 'refs/heads/master' # with #262 - 'refs/heads/${{{ github.default_branch }}}'
130130
steps:
131-
- uses: actions/checkout@v2
131+
- uses: actions/checkout@v3
132132
with:
133133
fetch-depth: 0
134-
- uses: actions/setup-node@v2
134+
- uses: actions/setup-node@v3
135135
with:
136136
node-version: lts/*
137137
- uses: ipfs/aegir/actions/cache-node-modules@master

README.md

+8-5
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
# ipfs-repo <!-- omit in toc -->
22

3-
[![ipfs.io](https://img.shields.io/badge/project-IPFS-blue.svg?style=flat-square)](http://ipfs.io)
4-
[![IRC](https://img.shields.io/badge/freenode-%23ipfs-blue.svg?style=flat-square)](http://webchat.freenode.net/?channels=%23ipfs)
5-
[![Discord](https://img.shields.io/discord/806902334369824788?style=flat-square)](https://discord.gg/ipfs)
3+
[![ipfs.tech](https://img.shields.io/badge/project-IPFS-blue.svg?style=flat-square)](https://ipfs.tech)
4+
[![Discuss](https://img.shields.io/discourse/https/discuss.ipfs.tech/posts.svg?style=flat-square)](https://discuss.ipfs.tech)
65
[![codecov](https://img.shields.io/codecov/c/github/ipfs/js-ipfs-repo.svg?style=flat-square)](https://codecov.io/gh/ipfs/js-ipfs-repo)
76
[![CI](https://img.shields.io/github/workflow/status/ipfs/js-ipfs-repo/test%20&%20maybe%20release/master?style=flat-square)](https://github.com/ipfs/js-ipfs-repo/actions/workflows/js-test-and-release.yml)
87

@@ -62,8 +61,12 @@ Licensed under either of
6261

6362
## Contribute
6463

65-
Feel free to join in. All welcome. Open an [issue](https://github.com/ipfs/js-ipfs-unixfs-importer/issues)!
64+
Contributions welcome! Please check out [the issues](https://github.com/ipfs/js-ipfs-repo/issues).
6665

67-
This repository falls under the IPFS [Code of Conduct](https://github.com/ipfs/community/blob/master/code-of-conduct.md).
66+
Also see our [contributing document](https://github.com/ipfs/community/blob/master/CONTRIBUTING_JS.md) for more information on how we work, and about contributing in general.
67+
68+
Please be aware that all interactions related to this repo are subject to the IPFS [Code of Conduct](https://github.com/ipfs/community/blob/master/code-of-conduct.md).
69+
70+
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.
6871

6972
[![](https://cdn.rawgit.com/jbenet/contribute-ipfs-gif/master/img/contribute.gif)](https://github.com/ipfs/community/blob/master/CONTRIBUTING.md)

lerna.json

+5-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
11
{
2-
"lerna": "4.0.0",
2+
"lerna": "5.4.0",
33
"useWorkspaces": true,
44
"version": "independent",
55
"command": {
66
"run": {
77
"stream": true
88
}
9-
}
9+
},
10+
"packages": [
11+
"packages/*"
12+
]
1013
}

package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@
3232
"dep-check": "lerna run dep-check",
3333
"release": "lerna run --concurrency 1 release -- --"
3434
},
35-
"devDependencies": {
36-
"lerna": "^5.0.0",
35+
"dependencies": {
36+
"lerna": "^6.0.0",
3737
"rimraf": "^3.0.2"
3838
},
3939
"workspaces": [

packages/ipfs-repo-migrations/README.md

+8-10
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
# ipfs-repo-migrations <!-- omit in toc -->
22

3-
[![ipfs.io](https://img.shields.io/badge/project-IPFS-blue.svg?style=flat-square)](http://ipfs.io)
4-
[![IRC](https://img.shields.io/badge/freenode-%23ipfs-blue.svg?style=flat-square)](http://webchat.freenode.net/?channels=%23ipfs)
5-
[![Discord](https://img.shields.io/discord/806902334369824788?style=flat-square)](https://discord.gg/ipfs)
3+
[![ipfs.tech](https://img.shields.io/badge/project-IPFS-blue.svg?style=flat-square)](https://ipfs.tech)
4+
[![Discuss](https://img.shields.io/discourse/https/discuss.ipfs.tech/posts.svg?style=flat-square)](https://discuss.ipfs.tech)
65
[![codecov](https://img.shields.io/codecov/c/github/ipfs/js-ipfs-repo.svg?style=flat-square)](https://codecov.io/gh/ipfs/js-ipfs-repo)
76
[![CI](https://img.shields.io/github/workflow/status/ipfs/js-ipfs-repo/test%20&%20maybe%20release/master?style=flat-square)](https://github.com/ipfs/js-ipfs-repo/actions/workflows/js-test-and-release.yml)
87

@@ -11,7 +10,6 @@
1110
## Table of contents <!-- omit in toc -->
1211

1312
- [Install](#install)
14-
- [Lead Maintainer <!-- omit in toc -->](#lead-maintainer----omit-in-toc---)
1513
- [Background](#background)
1614
- [Use in Node.js](#use-in-nodejs)
1715
- [Use in a browser with browserify, webpack or any other bundler](#use-in-a-browser-with-browserify-webpack-or-any-other-bundler)
@@ -50,10 +48,6 @@ $ npm i ipfs-repo-migrations
5048

5149
This package is inspired by the [go-ipfs repo migration tool](https://github.com/ipfs/fs-repo-migrations/)
5250

53-
## Lead Maintainer <!-- omit in toc -->
54-
55-
[Alex Potsides](http://github.com/achingbrain)
56-
5751
## Background
5852

5953
As js-ipfs evolves and new technologies, algorithms and data structures are incorporated it is necessary to
@@ -320,8 +314,12 @@ Licensed under either of
320314

321315
## Contribute
322316

323-
Feel free to join in. All welcome. Open an [issue](https://github.com/ipfs/js-ipfs-unixfs-importer/issues)!
317+
Contributions welcome! Please check out [the issues](https://github.com/ipfs/js-ipfs-repo/issues).
324318

325-
This repository falls under the IPFS [Code of Conduct](https://github.com/ipfs/community/blob/master/code-of-conduct.md).
319+
Also see our [contributing document](https://github.com/ipfs/community/blob/master/CONTRIBUTING_JS.md) for more information on how we work, and about contributing in general.
320+
321+
Please be aware that all interactions related to this repo are subject to the IPFS [Code of Conduct](https://github.com/ipfs/community/blob/master/code-of-conduct.md).
322+
323+
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.
326324

327325
[![](https://cdn.rawgit.com/jbenet/contribute-ipfs-gif/master/img/contribute.gif)](https://github.com/ipfs/community/blob/master/CONTRIBUTING.md)

packages/ipfs-repo-migrations/migrations/migration-9/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import { base32 } from 'multiformats/bases/base32'
1414
* @typedef {import('../../src/types').MigrationProgressCallback} MigrationProgressCallback
1515
* @typedef {import('interface-datastore').Datastore} Datastore
1616
* @typedef {import('interface-blockstore').Blockstore} Blockstore
17-
* @typedef {import('multiformats/cid').CIDVersion} CIDVersion
17+
* @typedef {import('multiformats/cid').Version} CIDVersion
1818
*/
1919

2020
/**

packages/ipfs-repo-migrations/package.json

+7-16
Original file line numberDiff line numberDiff line change
@@ -35,19 +35,12 @@
3535
"dist/*",
3636
"dist/src/*",
3737
"dist/src/*/index"
38-
],
39-
"migrations/*": [
40-
"*",
41-
"dist/*",
42-
"dist/migrations/*",
43-
"dist/migrations/*/index"
4438
]
4539
}
4640
},
4741
"files": [
4842
"src",
4943
"dist",
50-
"migrations",
5144
"!dist/test",
5245
"!**/*.tsbuildinfo"
5346
],
@@ -171,38 +164,36 @@
171164
"dep-check": "aegir dep-check -i interface-blockstore -i npm-run-all"
172165
},
173166
"dependencies": {
174-
"@ipld/dag-pb": "^2.1.0",
167+
"@ipld/dag-pb": "^3.0.0",
175168
"@multiformats/multiaddr": "^11.0.0",
176169
"cborg": "^1.3.4",
177170
"datastore-core": "^8.0.1",
178171
"debug": "^4.1.0",
179172
"fnv1a": "^1.0.1",
180173
"interface-blockstore": "^3.0.0",
181174
"interface-datastore": "^7.0.0",
182-
"it-length": "^1.0.1",
183-
"multiformats": "^9.0.4",
175+
"it-length": "^2.0.0",
176+
"multiformats": "^10.0.1",
184177
"protobufjs": "^7.0.0",
185-
"uint8arrays": "^3.0.0",
178+
"uint8arrays": "^4.0.2",
186179
"varint": "^6.0.0"
187180
},
188181
"devDependencies": {
189-
"@ipld/car": "^4.1.4",
182+
"@ipld/car": "^5.0.0",
190183
"@types/debug": "^4.1.5",
191-
"@types/rimraf": "^3.0.2",
192184
"@types/varint": "^6.0.0",
193185
"aegir": "^37.5.0",
194186
"aws-sdk": "^2.884.0",
195187
"blockstore-core": "^2.0.0",
196-
"blockstore-datastore-adapter": "^3.0.1",
188+
"blockstore-datastore-adapter": "^4.0.0",
197189
"datastore-fs": "^8.0.0",
198190
"datastore-level": "^9.0.0",
199191
"datastore-s3": "^10.0.0",
200-
"protobufjs-cli": "^1.0.0",
201192
"just-safe-set": "^4.1.1",
202193
"level-5": "npm:level@^5.0.0",
203194
"level-6": "npm:level@^6.0.0",
204195
"npm-run-all": "^4.1.5",
205-
"rimraf": "^3.0.2",
196+
"protobufjs-cli": "^1.0.0",
206197
"sinon": "^14.0.0"
207198
},
208199
"browser": {

packages/ipfs-repo-migrations/test/migrations/migration-9-test.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ import { base32 } from 'multiformats/bases/base32'
1616
* @typedef {import('interface-datastore').Datastore} Datastore
1717
* @typedef {import('interface-blockstore').Blockstore} Blockstore
1818
* @typedef {import('interface-datastore').Key} Key
19-
* @typedef {import('multiformats/cid').CIDVersion} CIDVersion
19+
* @typedef {import('multiformats/cid').Version} CIDVersion
2020
* @typedef {{ car: Uint8Array, root: CID, pins: number }} Pinset
2121
*/
2222

packages/ipfs-repo-migrations/test/node.js

+7-12
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/* eslint-env mocha */
22

33
import os from 'os'
4-
import rimraf from 'rimraf'
4+
import fs from 'fs/promises'
55
import { FsDatastore } from 'datastore-fs'
66
import { LevelDatastore } from 'datastore-level'
77
import { S3Datastore } from 'datastore-s3'
@@ -28,18 +28,13 @@ let s3Instance
2828
* @param {string} dir
2929
*/
3030
async function cleanup (dir) {
31-
/** @type {Promise<void>} */
32-
const p = new Promise((resolve, reject) => {
33-
rimraf(dir, (err) => {
34-
if (err) {
35-
reject(err)
36-
return
37-
}
38-
39-
resolve()
31+
try {
32+
await fs.rmdir(dir, {
33+
recursive: true
4034
})
41-
})
42-
await p
35+
} catch (/** @type {any} **/ err) {
36+
console.info('Could not delete', dir, err.stack) // eslint-disable-line no-console
37+
}
4338
}
4439

4540
const CONFIGURATIONS = [{

packages/ipfs-repo/README.md

+11-9
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
# ipfs-repo <!-- omit in toc -->
22

3-
[![ipfs.io](https://img.shields.io/badge/project-IPFS-blue.svg?style=flat-square)](http://ipfs.io)
4-
[![IRC](https://img.shields.io/badge/freenode-%23ipfs-blue.svg?style=flat-square)](http://webchat.freenode.net/?channels=%23ipfs)
5-
[![Discord](https://img.shields.io/discord/806902334369824788?style=flat-square)](https://discord.gg/ipfs)
3+
[![ipfs.tech](https://img.shields.io/badge/project-IPFS-blue.svg?style=flat-square)](https://ipfs.tech)
4+
[![Discuss](https://img.shields.io/discourse/https/discuss.ipfs.tech/posts.svg?style=flat-square)](https://discuss.ipfs.tech)
65
[![codecov](https://img.shields.io/codecov/c/github/ipfs/js-ipfs-repo.svg?style=flat-square)](https://codecov.io/gh/ipfs/js-ipfs-repo)
76
[![CI](https://img.shields.io/github/workflow/status/ipfs/js-ipfs-repo/test%20&%20maybe%20release/master?style=flat-square)](https://github.com/ipfs/js-ipfs-repo/actions/workflows/js-test-and-release.yml)
87

@@ -68,10 +67,6 @@ $ npm i ipfs-repo
6867

6968
This is the implementation of the [IPFS repo spec](https://github.com/ipfs/specs/blob/master/REPO.md) in JavaScript.
7069

71-
## Lead Maintainer <!-- omit in toc -->
72-
73-
[Alex Potsides](https://github.com/achingbrain)
74-
7570
## Background
7671

7772
Here is the architectural reasoning for this repo:
@@ -408,13 +403,20 @@ Licensed under either of
408403

409404
## Contribute
410405

411-
Feel free to join in. All welcome. Open an [issue](https://github.com/ipfs/js-ipfs-unixfs-importer/issues)!
406+
Contributions welcome! Please check out [the issues](https://github.com/ipfs/js-ipfs-repo/issues).
412407

413-
This repository falls under the IPFS [Code of Conduct](https://github.com/ipfs/community/blob/master/code-of-conduct.md).
408+
Also see our [contributing document](https://github.com/ipfs/community/blob/master/CONTRIBUTING_JS.md) for more information on how we work, and about contributing in general.
409+
410+
Please be aware that all interactions related to this repo are subject to the IPFS [Code of Conduct](https://github.com/ipfs/community/blob/master/code-of-conduct.md).
411+
412+
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.
414413

415414
[![](https://cdn.rawgit.com/jbenet/contribute-ipfs-gif/master/img/contribute.gif)](https://github.com/ipfs/community/blob/master/CONTRIBUTING.md)
416415

417416
[CID]: https://github.com/multiformats/js-cid
417+
418418
[Key]: https://github.com/ipfs/interface-datastore#keys
419+
419420
[Block]: https://github.com/ipld/js-ipld-block
421+
420422
[Multiaddr]: https://github.com/multiformats/js-multiaddr

0 commit comments

Comments
 (0)