v2.0.4-p1

This commit is contained in:
Cassandra Heart 2024-11-23 22:20:29 -06:00
parent 35d4b7a728
commit 269422b2f1
No known key found for this signature in database
GPG Key ID: 6352152859385958
2 changed files with 20 additions and 0 deletions

View File

@ -3,7 +3,10 @@
**/.vscode
github.env
Taskfile.yaml
.git
# Rust
target
vdf/generated
bls48581/generated

View File

@ -10,6 +10,7 @@ import (
"time"
pcrypto "github.com/libp2p/go-libp2p/core/crypto"
"github.com/libp2p/go-libp2p/core/peer"
"github.com/multiformats/go-multiaddr"
mn "github.com/multiformats/go-multiaddr/net"
"github.com/pkg/errors"
@ -53,6 +54,14 @@ func (r *DataWorkerIPCServer) CalculateChallengeProof(
challenge = append(challenge, req.ClockFrame.Output...)
difficulty = req.ClockFrame.Difficulty
frameNumber = req.ClockFrame.FrameNumber
r.logger.Debug(
"worker calculating challenge proof",
zap.String("peer_id", peer.ID(req.PeerId).String()),
zap.Uint32("core", req.Core),
zap.Uint64("frame_number", req.ClockFrame.FrameNumber),
zap.Uint32("difficulty", req.ClockFrame.Difficulty),
zap.Int("output_len", len(req.ClockFrame.Output)),
)
} else if req.Output != nil {
challenge = binary.BigEndian.AppendUint64(
challenge,
@ -60,6 +69,14 @@ func (r *DataWorkerIPCServer) CalculateChallengeProof(
)
challenge = binary.BigEndian.AppendUint32(challenge, req.Core)
challenge = append(challenge, req.Output...)
r.logger.Debug(
"worker calculating challenge proof",
zap.String("peer_id", peer.ID(req.PeerId).String()),
zap.Uint32("core", req.Core),
zap.Uint64("frame_number", req.FrameNumber),
zap.Uint32("difficulty", req.Difficulty),
zap.Int("output_len", len(req.Output)),
)
} else {
return nil, errors.Wrap(
errors.New("invalid request"),