mirror of
https://github.com/logos-storage/logos-storage-nim.git
synced 2026-06-03 01:00:01 +00:00
chore: cleanup dependencies (#1415)
Signed-off-by: Arnaud <arno.deville@gmail.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This commit is contained in:
parent
4ea8350612
commit
e8bc5c46e9
14
.gitmodules
vendored
14
.gitmodules
vendored
@ -33,11 +33,6 @@
|
||||
url = https://github.com/status-im/nim-stew.git
|
||||
ignore = untracked
|
||||
branch = master
|
||||
[submodule "vendor/nim-nitro"]
|
||||
path = vendor/nim-nitro
|
||||
url = https://github.com/status-im/nim-nitro.git
|
||||
ignore = untracked
|
||||
branch = main
|
||||
[submodule "vendor/questionable"]
|
||||
path = vendor/questionable
|
||||
url = https://github.com/status-im/questionable.git
|
||||
@ -131,15 +126,9 @@
|
||||
[submodule "vendor/nim-contract-abi"]
|
||||
path = vendor/nim-contract-abi
|
||||
url = https://github.com/status-im/nim-contract-abi
|
||||
[submodule "vendor/nim-json-rpc"]
|
||||
path = vendor/nim-json-rpc
|
||||
url = https://github.com/status-im/nim-json-rpc
|
||||
[submodule "vendor/nim-zlib"]
|
||||
path = vendor/nim-zlib
|
||||
url = https://github.com/status-im/nim-zlib
|
||||
[submodule "vendor/nim-ethers"]
|
||||
path = vendor/nim-ethers
|
||||
url = https://github.com/status-im/nim-ethers
|
||||
[submodule "vendor/lrucache.nim"]
|
||||
path = vendor/lrucache.nim
|
||||
url = https://github.com/status-im/lrucache.nim
|
||||
@ -167,9 +156,6 @@
|
||||
[submodule "vendor/nim-sqlite3-abi"]
|
||||
path = vendor/nim-sqlite3-abi
|
||||
url = https://github.com/arnetheduck/nim-sqlite3-abi.git
|
||||
[submodule "vendor/nim-eth"]
|
||||
path = vendor/nim-eth
|
||||
url = https://github.com/status-im/nim-eth
|
||||
[submodule "vendor/nim-protobuf-serialization"]
|
||||
path = vendor/nim-protobuf-serialization
|
||||
url = https://github.com/status-im/nim-protobuf-serialization
|
||||
|
||||
2
Makefile
2
Makefile
@ -145,7 +145,7 @@ test: | build deps
|
||||
# Builds and runs the integration tests
|
||||
testIntegration: | build deps
|
||||
echo -e $(BUILD_MSG) "build/$@" && \
|
||||
$(ENV_SCRIPT) nim testIntegration $(TEST_PARAMS) $(NIM_PARAMS) --define:ws_resubscribe=240 build.nims
|
||||
$(ENV_SCRIPT) nim testIntegration $(TEST_PARAMS) $(NIM_PARAMS) build.nims
|
||||
|
||||
# Builds a C example that uses the libstorage C library and runs it
|
||||
testLibstorage: | build deps
|
||||
|
||||
@ -1,6 +1,3 @@
|
||||
## Can be shared safely between threads
|
||||
type SharedSeq*[T] = tuple[data: ptr UncheckedArray[T], len: int]
|
||||
|
||||
proc alloc*(str: cstring): cstring =
|
||||
# Byte allocation from the given address.
|
||||
# There should be the corresponding manual deallocation with deallocShared !
|
||||
@ -22,21 +19,3 @@ proc alloc*(str: string): cstring =
|
||||
ret[i] = s[i]
|
||||
ret[str.len] = '\0'
|
||||
return ret
|
||||
|
||||
proc allocSharedSeq*[T](s: seq[T]): SharedSeq[T] =
|
||||
let data = allocShared(sizeof(T) * s.len)
|
||||
if s.len != 0:
|
||||
copyMem(data, unsafeAddr s[0], s.len)
|
||||
return (cast[ptr UncheckedArray[T]](data), s.len)
|
||||
|
||||
proc deallocSharedSeq*[T](s: var SharedSeq[T]) =
|
||||
deallocShared(s.data)
|
||||
s.len = 0
|
||||
|
||||
proc toSeq*[T](s: SharedSeq[T]): seq[T] =
|
||||
## Creates a seq[T] from a SharedSeq[T]. No explicit dealloc is required
|
||||
## as req[T] is a GC managed type.
|
||||
var ret = newSeq[T]()
|
||||
for i in 0 ..< s.len:
|
||||
ret.add(s.data[i])
|
||||
return ret
|
||||
|
||||
@ -11,7 +11,7 @@
|
||||
|
||||
import std/os
|
||||
|
||||
{.push warning[UnusedImport]: on.}
|
||||
{.push warning[UnusedImport]: off.}
|
||||
import std/terminal # Is not used in tests
|
||||
{.pop.}
|
||||
|
||||
|
||||
@ -10,7 +10,6 @@
|
||||
|
||||
import
|
||||
std/[options, os, strutils, times, net, atomics],
|
||||
stew/[objects],
|
||||
nat_traversal/[miniupnpc, natpmp],
|
||||
json_serialization/std/net,
|
||||
results
|
||||
|
||||
@ -12,7 +12,6 @@
|
||||
import std/options
|
||||
import std/sequtils
|
||||
import std/strformat
|
||||
import std/sugar
|
||||
import times
|
||||
|
||||
import pkg/taskpools
|
||||
|
||||
@ -19,7 +19,6 @@ import pkg/chronos
|
||||
import pkg/presto except toJson
|
||||
import pkg/metrics except toJson
|
||||
import pkg/stew/base10
|
||||
import pkg/stew/byteutils
|
||||
import pkg/confutils
|
||||
|
||||
import pkg/libp2p
|
||||
|
||||
@ -7,8 +7,6 @@
|
||||
## This file may not be copied, modified, or distributed except according to
|
||||
## those terms.
|
||||
|
||||
import std/sequtils
|
||||
import std/strutils
|
||||
import std/os
|
||||
import std/tables
|
||||
import std/cpuinfo
|
||||
@ -32,7 +30,6 @@ import ./stores
|
||||
import ./blockexchange
|
||||
import ./utils/fileutils
|
||||
import ./discovery
|
||||
import ./systemclock
|
||||
import ./utils/addrutils
|
||||
import ./namespaces
|
||||
import ./storagetypes
|
||||
|
||||
@ -8,7 +8,6 @@ import pkg/storage/stores
|
||||
import pkg/storage/units
|
||||
|
||||
import pkg/chronos
|
||||
import pkg/stew/byteutils
|
||||
import pkg/stint
|
||||
|
||||
import ./storage/helpers/randomchunker
|
||||
|
||||
@ -1,7 +1,6 @@
|
||||
import helpers/multisetup
|
||||
import helpers/trackers
|
||||
import helpers/templeveldb
|
||||
import std/times
|
||||
import std/sequtils, chronos
|
||||
|
||||
import ./asynctest
|
||||
|
||||
@ -1,7 +1,5 @@
|
||||
import std/importutils
|
||||
import std/net
|
||||
import std/sequtils
|
||||
import std/strformat
|
||||
from pkg/libp2p import `==`, `$`, Cid
|
||||
import pkg/storage/units
|
||||
import pkg/storage/manifest
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
import std/httpclient
|
||||
import std/os
|
||||
import std/sequtils
|
||||
import std/strutils
|
||||
import std/sugar
|
||||
import std/times
|
||||
@ -33,7 +32,6 @@ type
|
||||
MultiNodeSuiteError = object of CatchableError
|
||||
SuiteTimeoutError = object of MultiNodeSuiteError
|
||||
|
||||
const HardhatPort {.intdefine.}: int = 8545
|
||||
const StorageApiPort {.intdefine.}: int = 8080
|
||||
const StorageDiscPort {.intdefine.}: int = 8090
|
||||
const TestId {.strdefine.}: string = "TestId"
|
||||
@ -76,7 +74,6 @@ template multinodesuite*(suiteName: string, body: untyped) =
|
||||
var currentTestName = ""
|
||||
var nodeConfigs: NodeConfigs
|
||||
var snapshot: JsonNode
|
||||
var lastUsedHardhatPort = HardhatPort
|
||||
var lastUsedStorageApiPort = StorageApiPort
|
||||
var lastUsedStorageDiscPort = StorageDiscPort
|
||||
var storagePortLock: AsyncLock
|
||||
|
||||
@ -5,7 +5,6 @@ import pkg/chronicles
|
||||
import pkg/chronos/asyncproc
|
||||
import pkg/libp2p
|
||||
import std/os
|
||||
import std/strformat
|
||||
import std/strutils
|
||||
import storage/conf
|
||||
import storage/utils/exceptions
|
||||
|
||||
@ -1,9 +1,11 @@
|
||||
import std/os
|
||||
import std/strformat
|
||||
import pkg/chronos
|
||||
import pkg/chronos/asyncproc
|
||||
import pkg/storage/logutils
|
||||
|
||||
when defined(windows):
|
||||
import std/strformat
|
||||
import pkg/chronos/asyncproc
|
||||
|
||||
{.push raises: [].}
|
||||
|
||||
proc nextFreePort*(startPort: int): Future[int] {.async: (raises: [CancelledError]).} =
|
||||
|
||||
@ -4,8 +4,6 @@ import std/tables
|
||||
|
||||
import pkg/chronos
|
||||
|
||||
import pkg/libp2p/errors
|
||||
|
||||
import pkg/storage/rng
|
||||
import pkg/storage/stores
|
||||
import pkg/storage/blockexchange
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
import std/sequtils
|
||||
import std/algorithm
|
||||
import std/importutils
|
||||
|
||||
import pkg/chronos
|
||||
import pkg/stew/byteutils
|
||||
|
||||
@ -1,10 +1,7 @@
|
||||
import std/sequtils
|
||||
import std/random
|
||||
import std/algorithm
|
||||
|
||||
import pkg/stew/byteutils
|
||||
import pkg/chronos
|
||||
import pkg/libp2p/errors
|
||||
import pkg/libp2p/routing_record
|
||||
import pkg/codexdht/discv5/protocol as discv5
|
||||
|
||||
|
||||
@ -1,5 +1,4 @@
|
||||
import std/sequtils
|
||||
import std/times
|
||||
|
||||
import pkg/questionable/results
|
||||
import pkg/stew/byteutils
|
||||
|
||||
@ -6,7 +6,6 @@ import pkg/chronos
|
||||
import pkg/storage/storagetypes
|
||||
import pkg/storage/chunker
|
||||
import pkg/storage/stores
|
||||
import pkg/taskpools
|
||||
|
||||
import ../../asynctest
|
||||
|
||||
|
||||
@ -7,9 +7,7 @@ import pkg/chronos
|
||||
import pkg/stew/byteutils
|
||||
import pkg/datastore
|
||||
import pkg/datastore/typedds
|
||||
import pkg/questionable
|
||||
import pkg/questionable/results
|
||||
import pkg/stint
|
||||
import pkg/taskpools
|
||||
|
||||
import pkg/codexdht/discv5/protocol as discv5
|
||||
@ -22,7 +20,6 @@ import pkg/storage/blockexchange
|
||||
import pkg/storage/chunker
|
||||
import pkg/storage/manifest
|
||||
import pkg/storage/discovery
|
||||
import pkg/storage/merkletree
|
||||
import pkg/storage/blocktype as bt
|
||||
import pkg/storage/rng
|
||||
|
||||
|
||||
@ -9,8 +9,6 @@ import pkg/storage/merkletree
|
||||
import pkg/storage/manifest
|
||||
import pkg/storage/blocktype as bt
|
||||
import pkg/storage/chunker
|
||||
import pkg/storage/rng
|
||||
import pkg/taskpools
|
||||
|
||||
import ../helpers
|
||||
|
||||
|
||||
@ -14,12 +14,8 @@ import pkg/questionable/results
|
||||
import pkg/libp2p
|
||||
import pkg/storage/blocktype as bt
|
||||
import pkg/storage/stores/repostore
|
||||
import pkg/storage/clock
|
||||
|
||||
import ../../asynctest
|
||||
import ../helpers/mocktimer
|
||||
import ../helpers/mockrepostore
|
||||
import ../helpers/mockclock
|
||||
import ../examples
|
||||
|
||||
import storage/namespaces
|
||||
|
||||
@ -4,8 +4,6 @@ import pkg/storage/chunker
|
||||
import pkg/storage/blocktype as bt
|
||||
import pkg/storage/manifest
|
||||
|
||||
import pkg/storage/merkletree
|
||||
|
||||
import ../asynctest
|
||||
import ./helpers
|
||||
import ./examples
|
||||
|
||||
@ -1,10 +1,9 @@
|
||||
import std/[unittest, options, net]
|
||||
import std/[unittest, net]
|
||||
import pkg/chronos
|
||||
import pkg/libp2p/[multiaddress, multihash, multicodec]
|
||||
import pkg/results
|
||||
|
||||
import ../../storage/nat
|
||||
import ../../storage/utils/natutils
|
||||
import ../../storage/utils
|
||||
|
||||
suite "NAT Address Tests":
|
||||
|
||||
1
vendor/nim-eth
vendored
1
vendor/nim-eth
vendored
@ -1 +0,0 @@
|
||||
Subproject commit d9135e6c3c5d6d819afdfb566aa8d958756b73a8
|
||||
1
vendor/nim-ethers
vendored
1
vendor/nim-ethers
vendored
@ -1 +0,0 @@
|
||||
Subproject commit 965b8cd752544df96b5effecbbd27a8f56a25d62
|
||||
1
vendor/nim-json-rpc
vendored
1
vendor/nim-json-rpc
vendored
@ -1 +0,0 @@
|
||||
Subproject commit b6e40a776fa2d00b97a9366761fb7da18f31ae5c
|
||||
1
vendor/nim-nitro
vendored
1
vendor/nim-nitro
vendored
@ -1 +0,0 @@
|
||||
Subproject commit 5ccdeb46e06dcf5cef80d0acbb80ee8a17d596e7
|
||||
Loading…
x
Reference in New Issue
Block a user