Skip to content
This repository has been archived by the owner on Jun 27, 2023. It is now read-only.

Commit

Permalink
chore: update peer-id (#119)
Browse files Browse the repository at this point in the history
Pulls in new libp2p-crypto and peer-id

Also adds dependabot

BREAKING CHANGE: requires node 15+
  • Loading branch information
achingbrain committed Dec 2, 2021
1 parent 7075c63 commit 50eb30c
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 12 deletions.
2 changes: 1 addition & 1 deletion .aegir.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const PeerId = require('peer-id')

const WS = require('libp2p-websockets')
const MPLEX = require('libp2p-mplex')
const { NOISE } = require('libp2p-noise')
const { NOISE } = require('@chainsafe/libp2p-noise')

const RelayPeer = require('./test/fixtures/relay')

Expand Down
8 changes: 8 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
version: 2
updates:
- package-ecosystem: npm
directory: "/"
schedule:
interval: daily
time: "11:00"
open-pull-requests-limit: 10
19 changes: 17 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ jobs:
strategy:
matrix:
os: [windows-latest, ubuntu-latest, macos-latest]
node: [14, 16]
node: [16]
fail-fast: true
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
- uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}
- run: npm install @mapbox/node-pre-gyp -g
Expand All @@ -38,20 +38,29 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: lts/*
- run: npm install
- run: npx aegir test -t browser -t webworker --bail --timeout 60000
test-firefox:
needs: check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: lts/*
- run: npm install
- run: npx aegir test -t browser -t webworker --bail --timeout 60000 -- --browser firefox
test-webkit:
needs: check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: lts/*
- uses: microsoft/playwright-github-action@v1
- run: npm install
- run: npx aegir test -t browser --bail --timeout 60000 -- --browser webkit
Expand All @@ -60,12 +69,18 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: lts/*
- run: npm install
- run: npx xvfb-maybe aegir test -t electron-main --bail --timeout 60000
test-electron-renderer:
needs: check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: lts/*
- run: npm install
- run: npx xvfb-maybe aegir test -t electron-renderer --bail --timeout 60000
16 changes: 8 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,29 +43,29 @@
},
"homepage": "https://github.com/libp2p/js-libp2p-floodsub#readme",
"devDependencies": {
"@chainsafe/libp2p-noise": "^4.1.1",
"@types/debug": "^4.1.5",
"aegir": "^35.0.1",
"aegir": "^36.0.2",
"benchmark": "^2.1.4",
"buffer": "^6.0.3",
"chai": "^4.3.4",
"ipfs-utils": "^8.1.0",
"ipfs-utils": "^9.0.2",
"it-pair": "^1.0.0",
"libp2p": "^0.32.0",
"libp2p-interfaces-compliance-tests": "^1.0.1",
"libp2p": "^0.35.0",
"libp2p-interfaces-compliance-tests": "^2.0.3",
"libp2p-mplex": "^0.10.3",
"libp2p-noise": "^4.0.0",
"libp2p-websockets": "^0.16.0",
"multiaddr": "^10.0.0",
"multiformats": "^9.4.5",
"os": "^0.1.1",
"p-wait-for": "^3.1.0",
"peer-id": "^0.15.0",
"sinon": "^11.1.1",
"peer-id": "^0.16.0",
"sinon": "^12.0.1",
"util": "^0.12.3"
},
"dependencies": {
"debug": "^4.2.0",
"libp2p-interfaces": "^1.0.1",
"libp2p-interfaces": "^2.0.1",
"time-cache": "^0.3.0",
"uint8arrays": "^3.0.0"
},
Expand Down
1 change: 1 addition & 0 deletions test/floodsub.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ describe('floodsub', () => {

// receive the message once
await floodsub._processRpc(peerStream.id.toB58String(), peerStream, rpc)
await floodsub.queue.onIdle()

// should have received the message
expect(callCount).to.equal(1)
Expand Down
2 changes: 1 addition & 1 deletion test/utils/create-peer.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const PeerId = require('peer-id')
const WS = require('libp2p-websockets')
const filters = require('libp2p-websockets/src/filters')
const MPLEX = require('libp2p-mplex')
const { NOISE } = require('libp2p-noise')
const { NOISE } = require('@chainsafe/libp2p-noise')

const { isNode } = require('ipfs-utils/src/env')

Expand Down

0 comments on commit 50eb30c

Please sign in to comment.