mirror of
https://github.com/status-im/nim-libp2p.git
synced 2025-02-17 23:36:34 +00:00
Merging latest master and possible bug? (#552)
* put conditional locks on nbc bump (#549) * Fix minor exception issues (#550) Makes code compatible with https://github.com/status-im/nim-chronos/pull/166 without requiring it. * fix nimbus ref for auto-bump stable's PR * `doAssert` is `ValueError` not `AssertionError`? * Revert ValueError, fixed in chronos Co-authored-by: Giovanni Petrantoni <7008900+sinkingsugar@users.noreply.github.com> Co-authored-by: Jacek Sieka <jacek@status.im>
This commit is contained in:
parent
2c3613577b
commit
4081d2b9b7
3
.github/workflows/ci.yml
vendored
3
.github/workflows/ci.yml
vendored
@ -207,6 +207,7 @@ jobs:
|
||||
nimble test
|
||||
|
||||
bumpNBC-stable:
|
||||
if: github.ref == 'refs/heads/master'
|
||||
needs: build
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
@ -221,6 +222,7 @@ jobs:
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: status-im/nimbus-eth2
|
||||
ref: unstable
|
||||
path: nbc
|
||||
submodules: true
|
||||
fetch-depth: 0
|
||||
@ -246,6 +248,7 @@ jobs:
|
||||
title: nim-libp2p auto bump
|
||||
|
||||
bumpNBC-unstable:
|
||||
if: github.ref == 'refs/heads/unstable'
|
||||
needs: build
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
|
@ -42,7 +42,7 @@ proc isUpgraded*(s: Connection): bool =
|
||||
if not isNil(s.upgraded):
|
||||
return s.upgraded.finished
|
||||
|
||||
proc upgrade*(s: Connection, failed: ref Exception = nil) =
|
||||
proc upgrade*(s: Connection, failed: ref CatchableError = nil) =
|
||||
if not isNil(s.upgraded):
|
||||
if not isNil(failed):
|
||||
s.upgraded.fail(failed)
|
||||
|
@ -79,8 +79,6 @@ proc removePeerEventHandler*(s: Switch,
|
||||
kind: PeerEventKind) =
|
||||
s.connManager.removePeerEventHandler(handler, kind)
|
||||
|
||||
proc disconnect*(s: Switch, peerId: PeerID) {.async, gcsafe.}
|
||||
|
||||
proc isConnected*(s: Switch, peerId: PeerID): bool =
|
||||
## returns true if the peer has one or more
|
||||
## associated connections (sockets)
|
||||
|
@ -38,7 +38,7 @@ type
|
||||
opened*: uint64
|
||||
closed*: uint64
|
||||
|
||||
proc setupTcpTransportTracker(): TcpTransportTracker {.gcsafe.}
|
||||
proc setupTcpTransportTracker(): TcpTransportTracker {.gcsafe, raises: [Defect].}
|
||||
|
||||
proc getTcpTransportTracker(): TcpTransportTracker {.gcsafe.} =
|
||||
result = cast[TcpTransportTracker](getTracker(TcpTransportTrackerName))
|
||||
|
Loading…
x
Reference in New Issue
Block a user