diff --git a/.gitignore b/.gitignore index 815e1fa..cdc6f76 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,4 @@ -.core/ .idea/ +.vscode/ +*.log +.core/ diff --git a/go.mod b/go.mod index 9aca7ab..003f271 100644 --- a/go.mod +++ b/go.mod @@ -1,12 +1,12 @@ -module forge.lthn.ai/core/go-p2p +module dappco.re/go/core/p2p go 1.26.0 require ( + dappco.re/go/core/io v0.2.0 + dappco.re/go/core/log v0.1.0 forge.lthn.ai/Snider/Borg v0.3.1 forge.lthn.ai/Snider/Poindexter v0.0.3 - forge.lthn.ai/core/go-io v0.1.7 - forge.lthn.ai/core/go-log v0.0.4 github.com/adrg/xdg v0.5.3 github.com/google/uuid v1.6.0 github.com/gorilla/websocket v1.5.3 @@ -14,7 +14,8 @@ require ( ) require ( - forge.lthn.ai/Snider/Enchantrix v0.0.5 // indirect + forge.lthn.ai/Snider/Enchantrix v0.0.4 // indirect + forge.lthn.ai/core/go-log v0.0.4 // indirect github.com/ProtonMail/go-crypto v1.4.0 // indirect github.com/cloudflare/circl v1.6.3 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect diff --git a/go.sum b/go.sum index 3a68229..d7916fc 100644 --- a/go.sum +++ b/go.sum @@ -1,11 +1,13 @@ +dappco.re/go/core/io v0.2.0 h1:zuudgIiTsQQ5ipVt97saWdGLROovbEB/zdVyy9/l+I4= +dappco.re/go/core/io v0.2.0/go.mod h1:1QnQV6X9LNgFKfm8SkOtR9LLaj3bDcsOIeJOOyjbL5E= +dappco.re/go/core/log v0.1.0 h1:pa71Vq2TD2aoEUQWFKwNcaJ3GBY8HbaNGqtE688Unyc= +dappco.re/go/core/log v0.1.0/go.mod h1:Nkqb8gsXhZAO8VLpx7B8i1iAmohhzqA20b9Zr8VUcJs= forge.lthn.ai/Snider/Borg v0.3.1 h1:gfC1ZTpLoZai07oOWJiVeQ8+qJYK8A795tgVGJHbVL8= forge.lthn.ai/Snider/Borg v0.3.1/go.mod h1:Z7DJD0yHXsxSyM7Mjl6/g4gH1NBsIz44Bf5AFlV76Wg= -forge.lthn.ai/Snider/Enchantrix v0.0.5 h1:Yam0z+3AOvCUCHAMP68Ty8qHr2e4MMs7j2FjMM2JWc8= -forge.lthn.ai/Snider/Enchantrix v0.0.5/go.mod h1:/YcjKMNpC4Ze/fz7zbTx3djN0CJmSM83YiR2KaMK6zQ= +forge.lthn.ai/Snider/Enchantrix v0.0.4 h1:biwpix/bdedfyc0iVeK15awhhJKH6TEMYOTXzHXx5TI= +forge.lthn.ai/Snider/Enchantrix v0.0.4/go.mod h1:OGCwuVeZPq3OPe2h6TX/ZbgEjHU6B7owpIBeXQGbSe0= forge.lthn.ai/Snider/Poindexter v0.0.3 h1:cx5wRhuLRKBM8riIZyNVAT2a8rwRhn1dodFBktocsVE= forge.lthn.ai/Snider/Poindexter v0.0.3/go.mod h1:ddzGia98k3HKkR0gl58IDzqz+MmgW2cQJOCNLfuWPpo= -forge.lthn.ai/core/go-io v0.1.7 h1:Tdb6sqh+zz1lsGJaNX9RFWM6MJ/RhSAyxfulLXrJsbk= -forge.lthn.ai/core/go-io v0.1.7/go.mod h1:8lRLFk4Dnp5cR/Cyzh9WclD5566TbpdRgwcH7UZLWn4= forge.lthn.ai/core/go-log v0.0.4 h1:KTuCEPgFmuM8KJfnyQ8vPOU1Jg654W74h8IJvfQMfv0= forge.lthn.ai/core/go-log v0.0.4/go.mod h1:r14MXKOD3LF/sI8XUJQhRk/SZHBE7jAFVuCfgkXoZPw= github.com/ProtonMail/go-crypto v1.4.0 h1:Zq/pbM3F5DFgJiMouxEdSVY44MVoQNEKp5d5QxIQceQ= diff --git a/logging/logger.go b/logging/logger.go index f9247a7..4ab0666 100644 --- a/logging/logger.go +++ b/logging/logger.go @@ -10,7 +10,7 @@ import ( "sync" "time" - coreerr "forge.lthn.ai/core/go-log" + coreerr "dappco.re/go/core/log" ) // Level represents the severity of a log message. diff --git a/node/bundle.go b/node/bundle.go index 386bb8f..a9b8d07 100644 --- a/node/bundle.go +++ b/node/bundle.go @@ -11,8 +11,8 @@ import ( "path/filepath" "strings" - coreio "forge.lthn.ai/core/go-io" - coreerr "forge.lthn.ai/core/go-log" + coreio "dappco.re/go/core/io" + coreerr "dappco.re/go/core/log" "forge.lthn.ai/Snider/Borg/pkg/datanode" "forge.lthn.ai/Snider/Borg/pkg/tim" diff --git a/node/controller.go b/node/controller.go index 2b50122..224c4d6 100644 --- a/node/controller.go +++ b/node/controller.go @@ -6,9 +6,9 @@ import ( "sync" "time" - coreerr "forge.lthn.ai/core/go-log" + coreerr "dappco.re/go/core/log" - "forge.lthn.ai/core/go-p2p/logging" + "dappco.re/go/core/p2p/logging" ) // Controller manages remote peer operations from a controller node. diff --git a/node/dispatcher.go b/node/dispatcher.go index c7704a1..c240e18 100644 --- a/node/dispatcher.go +++ b/node/dispatcher.go @@ -5,10 +5,10 @@ import ( "iter" "sync" - coreerr "forge.lthn.ai/core/go-log" + coreerr "dappco.re/go/core/log" - "forge.lthn.ai/core/go-p2p/logging" - "forge.lthn.ai/core/go-p2p/ueps" + "dappco.re/go/core/p2p/logging" + "dappco.re/go/core/p2p/ueps" ) // ThreatScoreThreshold is the maximum allowable threat score. Packets exceeding diff --git a/node/dispatcher_test.go b/node/dispatcher_test.go index 971d44d..f817c03 100644 --- a/node/dispatcher_test.go +++ b/node/dispatcher_test.go @@ -6,7 +6,7 @@ import ( "sync/atomic" "testing" - "forge.lthn.ai/core/go-p2p/ueps" + "dappco.re/go/core/p2p/ueps" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" ) diff --git a/node/errors.go b/node/errors.go index 7128e07..218610b 100644 --- a/node/errors.go +++ b/node/errors.go @@ -1,6 +1,6 @@ package node -import coreerr "forge.lthn.ai/core/go-log" +import coreerr "dappco.re/go/core/log" // Sentinel errors shared across the node package. var ( diff --git a/node/identity.go b/node/identity.go index 53b07a3..5b650a5 100644 --- a/node/identity.go +++ b/node/identity.go @@ -12,8 +12,8 @@ import ( "sync" "time" - coreio "forge.lthn.ai/core/go-io" - coreerr "forge.lthn.ai/core/go-log" + coreio "dappco.re/go/core/io" + coreerr "dappco.re/go/core/log" "forge.lthn.ai/Snider/Borg/pkg/stmf" "github.com/adrg/xdg" diff --git a/node/integration_test.go b/node/integration_test.go index cd21f36..990419f 100644 --- a/node/integration_test.go +++ b/node/integration_test.go @@ -13,7 +13,7 @@ import ( "testing" "time" - "forge.lthn.ai/core/go-p2p/ueps" + "dappco.re/go/core/p2p/ueps" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" ) diff --git a/node/levin/header.go b/node/levin/header.go index c65c151..e93531f 100644 --- a/node/levin/header.go +++ b/node/levin/header.go @@ -8,7 +8,7 @@ package levin import ( "encoding/binary" - coreerr "forge.lthn.ai/core/go-log" + coreerr "dappco.re/go/core/log" ) // HeaderSize is the exact byte length of a serialised Levin header. diff --git a/node/levin/storage.go b/node/levin/storage.go index d9e7682..3d39718 100644 --- a/node/levin/storage.go +++ b/node/levin/storage.go @@ -10,7 +10,7 @@ import ( "math" "slices" - coreerr "forge.lthn.ai/core/go-log" + coreerr "dappco.re/go/core/log" ) // Portable storage signatures and version (9-byte header). diff --git a/node/levin/varint.go b/node/levin/varint.go index c895eb9..2830e71 100644 --- a/node/levin/varint.go +++ b/node/levin/varint.go @@ -6,7 +6,7 @@ package levin import ( "encoding/binary" - coreerr "forge.lthn.ai/core/go-log" + coreerr "dappco.re/go/core/log" ) // Size-mark bits occupying the two lowest bits of the first byte. diff --git a/node/peer.go b/node/peer.go index 6e7a115..d4ff02c 100644 --- a/node/peer.go +++ b/node/peer.go @@ -10,10 +10,11 @@ import ( "sync" "time" + coreio "dappco.re/go/core/io" + coreerr "dappco.re/go/core/log" + "dappco.re/go/core/p2p/logging" + poindexter "forge.lthn.ai/Snider/Poindexter" - coreio "forge.lthn.ai/core/go-io" - coreerr "forge.lthn.ai/core/go-log" - "forge.lthn.ai/core/go-p2p/logging" "github.com/adrg/xdg" ) diff --git a/node/protocol.go b/node/protocol.go index 203e651..80ca346 100644 --- a/node/protocol.go +++ b/node/protocol.go @@ -3,7 +3,7 @@ package node import ( "fmt" - coreerr "forge.lthn.ai/core/go-log" + coreerr "dappco.re/go/core/log" ) // ProtocolError represents an error from the remote peer. diff --git a/node/transport.go b/node/transport.go index 3f79aef..e30c0e5 100644 --- a/node/transport.go +++ b/node/transport.go @@ -15,10 +15,10 @@ import ( "sync/atomic" "time" - coreerr "forge.lthn.ai/core/go-log" + coreerr "dappco.re/go/core/log" + "dappco.re/go/core/p2p/logging" "forge.lthn.ai/Snider/Borg/pkg/smsg" - "forge.lthn.ai/core/go-p2p/logging" "github.com/gorilla/websocket" ) diff --git a/node/worker.go b/node/worker.go index ffbb874..af917d4 100644 --- a/node/worker.go +++ b/node/worker.go @@ -6,9 +6,9 @@ import ( "path/filepath" "time" - coreerr "forge.lthn.ai/core/go-log" + coreerr "dappco.re/go/core/log" - "forge.lthn.ai/core/go-p2p/logging" + "dappco.re/go/core/p2p/logging" "github.com/adrg/xdg" ) diff --git a/ueps/packet.go b/ueps/packet.go index 2f5c101..0fb590c 100644 --- a/ueps/packet.go +++ b/ueps/packet.go @@ -7,7 +7,7 @@ import ( "encoding/binary" "io" - coreerr "forge.lthn.ai/core/go-log" + coreerr "dappco.re/go/core/log" ) // TLV Types diff --git a/ueps/reader.go b/ueps/reader.go index 245f216..dcd1fe7 100644 --- a/ueps/reader.go +++ b/ueps/reader.go @@ -8,7 +8,7 @@ import ( "encoding/binary" "io" - coreerr "forge.lthn.ai/core/go-log" + coreerr "dappco.re/go/core/log" ) // ParsedPacket holds the verified data