Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chore/update nim version #1052

Merged
merged 47 commits into from
Jan 10, 2025
Merged
Show file tree
Hide file tree
Changes from 37 commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
b5af96f
Move to version 2.0.6
2-towns Nov 28, 2024
ca2b63c
Update nim-confutils submodule to latest version
2-towns Nov 28, 2024
ef3274b
Update dependencies
2-towns Dec 18, 2024
34f5e00
Update Nim version to 2.0.12
2-towns Dec 18, 2024
7c9b607
Add gcsafe pragma
2-towns Dec 18, 2024
0e00f0c
Add missing import
2-towns Dec 18, 2024
0ecf3f7
Update specific conf for Nim 2.x
2-towns Dec 18, 2024
4935494
Fix method signatures
2-towns Dec 18, 2024
a1c8c94
Revert erasure coding attempt to fix bug
2-towns Dec 18, 2024
599e868
More gcsafe pragma
2-towns Dec 18, 2024
a2f0528
Duplicate code from libp2p because it is not exported anymore
2-towns Dec 18, 2024
a2f09b2
Fix camelcase function names
2-towns Dec 18, 2024
902c6dc
Use alreadySeen because need is not a bool anymore
2-towns Dec 18, 2024
83b4943
newLPStreamReadError does not exist anymore so use another error
2-towns Dec 18, 2024
daadffe
Replace ValidIpAddress by IpAddress
2-towns Dec 18, 2024
d6b1781
Add gcsafe pragma
2-towns Dec 26, 2024
0724d7f
Restore maintenance parameter deleted by mistake when removing esasur…
2-towns Dec 26, 2024
6ad496d
Update method signatures
2-towns Dec 26, 2024
5c80a84
Copy LPStreamReadError code from libp2p which was removed
2-towns Dec 26, 2024
6b64c25
Fix camel case
2-towns Dec 26, 2024
627e6ae
Fix enums in tests
2-towns Dec 26, 2024
51a4054
Fix camel case
2-towns Dec 26, 2024
ab39da8
Extract node components to a variable to make Nim 2 happy
2-towns Dec 26, 2024
3f9f421
Update the tests using ValidIpAddress to IpAddress
2-towns Dec 26, 2024
d2388a3
Fix cast for value which is already an option
2-towns Dec 27, 2024
b9222d0
Merge branch 'master' into chore/update-nim-version
2-towns Dec 30, 2024
d9eca3b
Set nim version to 2.0.x for CI
2-towns Jan 2, 2025
696f66d
Set nim version to 2.0.x for CI
2-towns Jan 2, 2025
56d2186
Move to miniupnp version 2.2.4 to avoid symlink error
2-towns Jan 3, 2025
1ecad68
Set core.symlinks to false for Windows for miniupnp >= 2.2.5 support
2-towns Jan 6, 2025
7bdbd87
Update to Nim 2.0.14
2-towns Jan 7, 2025
dfcdac6
Update CI nim versions to 2.0.14
2-towns Jan 7, 2025
f24d264
Try with GCC 14
2-towns Jan 8, 2025
fdba4e7
Replace apt-fast by apt-get
2-towns Jan 8, 2025
251d286
Update ubuntu runner to latest
2-towns Jan 8, 2025
b5848da
Use Ubuntu 20.04 for coverage
2-towns Jan 9, 2025
801f6b7
Disable CI cache for coverage
2-towns Jan 9, 2025
2c436db
Add coverage property description
2-towns Jan 9, 2025
958df72
Remove commented test
2-towns Jan 9, 2025
08ced59
Check the node value of seen instead of using alreadySeen
2-towns Jan 9, 2025
00e3f0e
Merge branch 'master' into chore/update-nim-version
2-towns Jan 9, 2025
10bc903
Fix the merge. The taskpool work was reverted.
2-towns Jan 9, 2025
66d1c5b
Update nim-ethers submodule
2-towns Jan 9, 2025
943ca8a
Merge branch 'master' into chore/update-nim-version
2-towns Jan 10, 2025
fb14b60
Remove deprecated ValidIpAddress. Fix missing case and imports.
2-towns Jan 10, 2025
5cbb43b
Fix a weird issue where nim-confutils cannot find NatAny
2-towns Jan 10, 2025
0d71b0a
Fix tests and remove useless static keyword
2-towns Jan 10, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 25 additions & 7 deletions .github/actions/nimbus-build-system/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ inputs:
default: "amd64"
nim_version:
description: "Nim version"
default: "version-1-6"
default: "v2.0.14"
rust_version:
description: "Rust version"
default: "1.79.0"
Expand All @@ -31,17 +31,17 @@ runs:
if: inputs.os == 'linux' && (inputs.cpu == 'amd64' || inputs.cpu == 'arm64')
shell: ${{ inputs.shell }} {0}
run: |
sudo apt-fast update -qq
sudo DEBIAN_FRONTEND='noninteractive' apt-fast install \
sudo apt-get update -qq
sudo DEBIAN_FRONTEND='noninteractive' apt-get install \
--no-install-recommends -yq lcov
- name: APT (Linux i386)
if: inputs.os == 'linux' && inputs.cpu == 'i386'
shell: ${{ inputs.shell }} {0}
run: |
sudo dpkg --add-architecture i386
sudo apt-fast update -qq
sudo DEBIAN_FRONTEND='noninteractive' apt-fast install \
sudo apt-get update -qq
sudo DEBIAN_FRONTEND='noninteractive' apt-get install \
--no-install-recommends -yq gcc-multilib g++-multilib
- name: Homebrew (macOS)
Expand Down Expand Up @@ -78,11 +78,21 @@ runs:
mingw-w64-i686-ntldd-git
mingw-w64-i686-rust
- name: MSYS2 (Windows All) - Downgrade to gcc 13
- name: MSYS2 (Windows All) - Update to gcc 14
if: inputs.os == 'windows'
shell: ${{ inputs.shell }} {0}
run: |
pacman -U --noconfirm https://repo.msys2.org/mingw/ucrt64/mingw-w64-ucrt-x86_64-gcc-13.2.0-6-any.pkg.tar.zst https://repo.msys2.org/mingw/ucrt64/mingw-w64-ucrt-x86_64-gcc-libs-13.2.0-6-any.pkg.tar.zst
pacman -U --noconfirm https://repo.msys2.org/mingw/ucrt64/mingw-w64-ucrt-x86_64-gcc-14.2.0-2-any.pkg.tar.zst https://repo.msys2.org/mingw/ucrt64/mingw-w64-ucrt-x86_64-gcc-libs-14.2.0-2-any.pkg.tar.zst
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Windows is installing latest GCC version, which currently is 14 and 15 is on the way :)

We can remove this step, but later we might have an issue with version 15 (?).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For Windows 2025 right ?

But the windows-latest is still pointing on windows-2022 which is using gcc 12.

Copy link
Contributor

@veaceslavdoina veaceslavdoina Jan 9, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are not relying on the preinstalled GCC on Windows. It is about MSYS2 and how it works

MSYS2 is a rolling release distribution

At some point, it will just install latest GCC and version 15 will be released in March~April (#875 (comment)). It will appear in MSYS2 repository with a delay and we can expect an issue in August, as we had it with the version 14 😄

So, if we remove that step, we can get in the the issue in August, but will have latest GCC releases all the time.

Let's leave it to have a stable CI?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are not relying on the preinstalled GCC on Windows. It is about MSYS2 and how it works

Ah ok.

Let's leave it to have a stable CI?

Yeah I agree. I prefer to leave it for now and after testing GCC 15, we could remove it.

- name: Install gcc 14 on Linux
# We don't want to install gcc 14 for coverage (Ubuntu 20.04)
if : ${{ inputs.os == 'linux' && !inputs.coverage }}
shell: ${{ inputs.shell }} {0}
run: |
# Add GCC-14 to alternatives
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-14 14
# Set GCC-14 as the default
sudo update-alternatives --set gcc /usr/bin/gcc-14
- name: Derive environment variables
shell: ${{ inputs.shell }} {0}
Expand Down Expand Up @@ -159,6 +169,7 @@ runs:
- name: Restore Nim toolchain binaries from cache
id: nim-cache
uses: actions/cache@v4
if : ${{ !inputs.coverage }}
with:
path: NimBinaries
key: ${{ inputs.os }}-${{ inputs.cpu }}-nim-${{ inputs.nim_version }}-cache-${{ env.cache_nonce }}-${{ github.run_id }}
Expand All @@ -168,9 +179,16 @@ runs:
shell: ${{ inputs.shell }} {0}
run: echo "NIM_COMMIT=${{ inputs.nim_version }}" >> ${GITHUB_ENV}

- name: MSYS2 (Windows All) - Disable git symbolic links (since miniupnp 2.2.5)
if: inputs.os == 'windows'
shell: ${{ inputs.shell }} {0}
run: |
git config --global core.symlinks false
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@veaceslavdoina Double check if it is okay for you

- name: Build Nim and Codex dependencies
shell: ${{ inputs.shell }} {0}
run: |
gcc --version
make -j${ncpu} CI_CACHE=NimBinaries ${ARCH_OVERRIDE} QUICK_AND_DIRTY_COMPILER=1 update
echo
./env.sh nim --version
1 change: 1 addition & 0 deletions .github/workflows/ci-reusable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ jobs:
os: ${{ matrix.os }}
shell: ${{ matrix.shell }}
nim_version: ${{ matrix.nim_version }}
coverage: false
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should add an input coverage to the .github/actions/nimbus-build-system/action.yml and set it false by default, than pass true just for coverage (we are doing it already).

https://github.com/codex-storage/nim-codex/actions/runs/12689785802
Screenshot 2025-01-09 at 16 12 51


## Part 1 Tests ##
- name: Unit tests
Expand Down
15 changes: 10 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:

env:
cache_nonce: 0 # Allows for easily busting actions/cache caches
nim_version: pinned
nim_version: v2.0.14

concurrency:
group: ${{ github.workflow }}-${{ github.ref || github.run_id }}
Expand All @@ -27,10 +27,10 @@ jobs:
uses: fabiocaccamo/create-matrix-action@v4
with:
matrix: |
os {linux}, cpu {amd64}, builder {ubuntu-20.04}, tests {unittest}, nim_version {${{ env.nim_version }}}, shell {bash --noprofile --norc -e -o pipefail}
os {linux}, cpu {amd64}, builder {ubuntu-20.04}, tests {contract}, nim_version {${{ env.nim_version }}}, shell {bash --noprofile --norc -e -o pipefail}
os {linux}, cpu {amd64}, builder {ubuntu-20.04}, tests {integration}, nim_version {${{ env.nim_version }}}, shell {bash --noprofile --norc -e -o pipefail}
os {linux}, cpu {amd64}, builder {ubuntu-20.04}, tests {tools}, nim_version {${{ env.nim_version }}}, shell {bash --noprofile --norc -e -o pipefail}
os {linux}, cpu {amd64}, builder {ubuntu-latest}, tests {unittest}, nim_version {${{ env.nim_version }}}, shell {bash --noprofile --norc -e -o pipefail}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We switched to ubuntu-20.04 in #939 and because of the #932.

Probably we should stick with the 20.04?

Btw, we also have a release workflow and 20.04 is required mostly for releases. But as I remember, there can be an issue when cache from latest (24.04) is restored on 20.04 and vice versa.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably we should stick with the 20.04?

There are two problems: 1- 20.04 will be deprecated soon, 2- I am not sure I will be able to install GCC 14 on ubuntu 20.04.

Maybe #932 is fixed now with the update to Nim 2.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was related to the glibc version. So, new releases will not run on old distributions.

The Ubuntu 20.04 Actions runner image will begin deprecation on 2025-02-01 and will be fully unsupported by 2025-04-01 #11101

Deprecation will begin on 2025-02-01 and the image will be fully unsupported by 2025-04-01.

The Ubuntu lifecycle and release cadence
Screenshot 2025-01-09 at 17 05 20

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this is what we discussed yesterday.

os {linux}, cpu {amd64}, builder {ubuntu-latest}, tests {contract}, nim_version {${{ env.nim_version }}}, shell {bash --noprofile --norc -e -o pipefail}
os {linux}, cpu {amd64}, builder {ubuntu-latest}, tests {integration}, nim_version {${{ env.nim_version }}}, shell {bash --noprofile --norc -e -o pipefail}
os {linux}, cpu {amd64}, builder {ubuntu-latest}, tests {tools}, nim_version {${{ env.nim_version }}}, shell {bash --noprofile --norc -e -o pipefail}
os {macos}, cpu {amd64}, builder {macos-13}, tests {unittest}, nim_version {${{ env.nim_version }}}, shell {bash --noprofile --norc -e -o pipefail}
os {macos}, cpu {amd64}, builder {macos-13}, tests {contract}, nim_version {${{ env.nim_version }}}, shell {bash --noprofile --norc -e -o pipefail}
os {macos}, cpu {amd64}, builder {macos-13}, tests {integration}, nim_version {${{ env.nim_version }}}, shell {bash --noprofile --norc -e -o pipefail}
Expand All @@ -48,6 +48,10 @@ jobs:
cache_nonce: ${{ needs.matrix.outputs.cache_nonce }}

coverage:
# Force to stick to ubuntu 20.04 for coverage because
# lcov was updated to 2.x version in ubuntu-latest
# and cause a lot of issues.
# See https://github.com/linux-test-project/lcov/issues/238
runs-on: ubuntu-20.04
steps:
- name: Checkout sources
Expand All @@ -61,6 +65,7 @@ jobs:
with:
os: linux
nim_version: ${{ env.nim_version }}
coverage: true

- name: Generate coverage data
run: |
Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
#
# If NIM_COMMIT is set to "nimbusbuild", this will use the
# version pinned by nimbus-build-system.
PINNED_NIM_VERSION := 38640664088251bbc88917b4bacfd86ec53014b8 # 1.6.21

#PINNED_NIM_VERSION := 38640664088251bbc88917b4bacfd86ec53014b8 # 1.6.21
PINNED_NIM_VERSION := v2.0.14
ifeq ($(NIM_COMMIT),)
NIM_COMMIT := $(PINNED_NIM_VERSION)
else ifeq ($(NIM_COMMIT),pinned)
Expand Down
6 changes: 3 additions & 3 deletions codex.nim
Original file line number Diff line number Diff line change
Expand Up @@ -48,18 +48,18 @@ when isMainModule:
let config = CodexConf.load(
version = codexFullVersion,
envVarsPrefix = "codex",
secondarySources = proc (config: CodexConf, sources: auto) =
secondarySources = proc (config: CodexConf, sources: auto) {.gcsafe, raises: [ConfigurationError].} =
if configFile =? config.configFile:
sources.addConfigFile(Toml, configFile)
)
config.setupLogging()
config.setupMetrics()

if config.nat == ValidIpAddress.init(IPv4_any()):
if config.nat == IPv4_any():
error "`--nat` cannot be set to the any (`0.0.0.0`) address"
quit QuitFailure

if config.nat == ValidIpAddress.init("127.0.0.1"):
if config.nat == static parseIpAddress("127.0.0.1"):
warn "`--nat` is set to loopback, your node wont properly announce over the DHT"

if not(checkAndCreateDataDir((config.dataDir).string)):
Expand Down
2 changes: 1 addition & 1 deletion codex/clock.nim
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ type
SecondsSince1970* = int64
Timeout* = object of CatchableError

method now*(clock: Clock): SecondsSince1970 {.base, upraises: [].} =
method now*(clock: Clock): SecondsSince1970 {.base, gcsafe, upraises: [].} =
raiseAssert "not implemented"

method waitUntil*(clock: Clock, time: SecondsSince1970) {.base, async.} =
Expand Down
15 changes: 2 additions & 13 deletions codex/codex.nim
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import std/sequtils
import std/strutils
import std/os
import std/tables
import std/cpuinfo

import pkg/chronos
import pkg/presto
Expand All @@ -24,7 +23,6 @@ import pkg/stew/shims/net as stewnet
import pkg/datastore
import pkg/ethers except Rng
import pkg/stew/io2
import pkg/taskpools

import ./node
import ./conf
Expand Down Expand Up @@ -55,7 +53,6 @@ type
codexNode: CodexNodeRef
repoStore: RepoStore
maintenance: BlockMaintainer
taskpool: Taskpool

CodexPrivateKey* = libp2p.PrivateKey # alias
EthWallet = ethers.Wallet
Expand Down Expand Up @@ -190,10 +187,6 @@ proc start*(s: CodexServer) {.async.} =
proc stop*(s: CodexServer) {.async.} =
notice "Stopping codex node"


s.taskpool.syncAll()
s.taskpool.shutdown()

await allFuturesThrowing(
s.restServer.stop(),
s.codexNode.switch.stop(),
Expand Down Expand Up @@ -283,15 +276,12 @@ proc new*(
else:
none Prover

taskpool = Taskpool.new(num_threads = countProcessors())

codexNode = CodexNodeRef.new(
switch = switch,
networkStore = store,
engine = engine,
prover = prover,
discovery = discovery,
taskpool = taskpool)
prover = prover)

restServer = RestServerRef.new(
codexNode.initRestApi(config, repoStore, config.apiCorsAllowedOrigin),
Expand All @@ -307,5 +297,4 @@ proc new*(
codexNode: codexNode,
restServer: restServer,
repoStore: repoStore,
maintenance: maintenance,
taskpool: taskpool)
maintenance: maintenance)
40 changes: 27 additions & 13 deletions codex/conf.nim
Original file line number Diff line number Diff line change
Expand Up @@ -113,9 +113,9 @@ type

metricsAddress* {.
desc: "Listening address of the metrics server"
defaultValue: ValidIpAddress.init("127.0.0.1")
defaultValue: defaultAddress(config)
defaultValueDesc: "127.0.0.1"
name: "metrics-address" }: ValidIpAddress
name: "metrics-address" }: IpAddress

metricsPort* {.
desc: "Listening HTTP port of the metrics server"
Expand All @@ -141,17 +141,17 @@ type
# TODO: change this once we integrate nat support
nat* {.
desc: "IP Addresses to announce behind a NAT"
defaultValue: ValidIpAddress.init("127.0.0.1")
defaultValue: defaultAddress(config)
defaultValueDesc: "127.0.0.1"
abbr: "a"
name: "nat" }: ValidIpAddress
name: "nat" }: IpAddress

discoveryIp* {.
desc: "Discovery listen address"
defaultValue: ValidIpAddress.init(IPv4_any())
defaultValue: IPv4_any()
defaultValueDesc: "0.0.0.0"
abbr: "e"
name: "disc-ip" }: ValidIpAddress
name: "disc-ip" }: IpAddress

discoveryPort* {.
desc: "Discovery (UDP) port"
Expand Down Expand Up @@ -412,6 +412,9 @@ type
logutils.formatIt(LogFormat.textLines, EthAddress): it.short0xHexLog
logutils.formatIt(LogFormat.json, EthAddress): %it

func defaultAddress*(conf: CodexConf): IpAddress =
result = static parseIpAddress("127.0.0.1")

func persistence*(self: CodexConf): bool =
self.cmd == StartUpCmd.persistence

Expand Down Expand Up @@ -444,13 +447,17 @@ const

proc parseCmdArg*(T: typedesc[MultiAddress],
input: string): MultiAddress
{.upraises: [ValueError, LPError].} =
{.upraises: [ValueError] .} =
var ma: MultiAddress
let res = MultiAddress.init(input)
if res.isOk:
ma = res.get()
else:
warn "Invalid MultiAddress", input=input, error = res.error()
try:
let res = MultiAddress.init(input)
if res.isOk:
ma = res.get()
else:
warn "Invalid MultiAddress", input=input, error = res.error()
quit QuitFailure
except LPError as exc:
warn "Invalid MultiAddress uri", uri = input, error = exc.msg
quit QuitFailure
ma

Expand All @@ -460,6 +467,9 @@ proc parseCmdArg*(T: type SignedPeerRecord, uri: string): T =
if not res.fromURI(uri):
warn "Invalid SignedPeerRecord uri", uri = uri
quit QuitFailure
except LPError as exc:
warn "Invalid SignedPeerRecord uri", uri = uri, error = exc.msg
quit QuitFailure
except CatchableError as exc:
warn "Invalid SignedPeerRecord uri", uri = uri, error = exc.msg
quit QuitFailure
Expand Down Expand Up @@ -493,7 +503,11 @@ proc readValue*(r: var TomlReader, val: var SignedPeerRecord) =
error "invalid SignedPeerRecord configuration value", error = err.msg
quit QuitFailure

val = SignedPeerRecord.parseCmdArg(uri)
try:
val = SignedPeerRecord.parseCmdArg(uri)
except LPError as err:
warn "Invalid SignedPeerRecord uri", uri = uri, error = err.msg
quit QuitFailure

proc readValue*(r: var TomlReader, val: var MultiAddress) =
without input =? r.readValue(string).catch, err:
Expand Down
9 changes: 5 additions & 4 deletions codex/discovery.nim
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
import pkg/stew/shims/net
import pkg/contractabi/address as ca
import pkg/codexdht/discv5/[routing_table, protocol as discv5]
from pkg/nimcrypto import keccak256

import ./rng
import ./errors
Expand Down Expand Up @@ -124,7 +125,7 @@

method removeProvider*(
d: Discovery,
peerId: PeerId): Future[void] {.base.} =
peerId: PeerId): Future[void] {.base, gcsafe.} =

Check warning on line 128 in codex/discovery.nim

View check run for this annotation

Codecov / codecov/patch

codex/discovery.nim#L128

Added line #L128 was not covered by tests
## Remove provider from providers table
##

Expand All @@ -146,7 +147,7 @@
d.protocol.updateRecord(d.providerRecord)
.expect("Should update SPR")

proc updateDhtRecord*(d: Discovery, ip: ValidIpAddress, port: Port) =
proc updateDhtRecord*(d: Discovery, ip: IpAddress, port: Port) =
## Update providers record
##

Expand All @@ -172,7 +173,7 @@
proc new*(
T: type Discovery,
key: PrivateKey,
bindIp = ValidIpAddress.init(IPv4_any()),
bindIp = IPv4_any(),
bindPort = 0.Port,
announceAddrs: openArray[MultiAddress],
bootstrapNodes: openArray[SignedPeerRecord] = [],
Expand Down Expand Up @@ -202,7 +203,7 @@

self.protocol = newProtocol(
key,
bindIp = bindIp.toNormalIp,
bindIp = bindIp,

Check warning on line 206 in codex/discovery.nim

View check run for this annotation

Codecov / codecov/patch

codex/discovery.nim#L206

Added line #L206 was not covered by tests
bindPort = bindPort,
record = self.providerRecord.get,
bootstrapRecords = bootstrapNodes,
Expand Down
6 changes: 3 additions & 3 deletions codex/erasure/backend.nim
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
EncoderBackend* = ref object of ErasureBackend
DecoderBackend* = ref object of ErasureBackend

method release*(self: ErasureBackend) {.base.} =
method release*(self: ErasureBackend) {.base, gcsafe.} =
## release the backend
##
raiseAssert("not implemented!")
Expand All @@ -31,7 +31,7 @@
self: EncoderBackend,
buffers,
parity: var openArray[seq[byte]]
): Result[void, cstring] {.base.} =
): Result[void, cstring] {.base, gcsafe.} =

Check warning on line 34 in codex/erasure/backend.nim

View check run for this annotation

Codecov / codecov/patch

codex/erasure/backend.nim#L34

Added line #L34 was not covered by tests
## encode buffers using a backend
##
raiseAssert("not implemented!")
Expand All @@ -41,7 +41,7 @@
buffers,
parity,
recovered: var openArray[seq[byte]]
): Result[void, cstring] {.base.} =
): Result[void, cstring] {.base, gcsafe.} =

Check warning on line 44 in codex/erasure/backend.nim

View check run for this annotation

Codecov / codecov/patch

codex/erasure/backend.nim#L44

Added line #L44 was not covered by tests
## decode buffers using a backend
##
raiseAssert("not implemented!")
Loading
Loading