From 6d5044cb6ad742fd8539dbb19949a458b3704441 Mon Sep 17 00:00:00 2001 From: colinaumaty Date: Thu, 24 Sep 2026 17:35:22 +0800 Subject: [PATCH] chore: minor improvement for docs Signed-off-by: colinaumaty --- pkg/cmd/run_node.go | 2 +- pkg/raft/election_test.go | 2 +- pkg/rpc/server/tracing.go | 2 +- pkg/sequencers/single/queue.go | 2 +- pkg/service/baseservice_test.go | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/pkg/cmd/run_node.go b/pkg/cmd/run_node.go index a5f667bee1..b6bdeb64b9 100644 --- a/pkg/cmd/run_node.go +++ b/pkg/cmd/run_node.go @@ -28,7 +28,7 @@ import ( "github.com/evstack/ev-node/pkg/telemetry" ) -// ParseConfig is a helper that loads the node configuration and validates it. +// ParseConfig is a helper function that loads the node configuration and validates it. func ParseConfig(cmd *cobra.Command) (rollconf.Config, error) { nodeConfig, err := rollconf.Load(cmd) if err != nil { diff --git a/pkg/raft/election_test.go b/pkg/raft/election_test.go index 5510b29819..4f0c947933 100644 --- a/pkg/raft/election_test.go +++ b/pkg/raft/election_test.go @@ -444,7 +444,7 @@ func TestDynamicLeaderElectionRun(t *testing.T) { } } -// Helper to quickly build a Config with very short timeouts for tests +// testCfg is a helper to quickly build a Config with very short timeouts for tests. func testCfg() Config { return Config{SendTimeout: 2 * time.Millisecond} } diff --git a/pkg/rpc/server/tracing.go b/pkg/rpc/server/tracing.go index 8448285e0a..0f6f2eb444 100644 --- a/pkg/rpc/server/tracing.go +++ b/pkg/rpc/server/tracing.go @@ -214,7 +214,7 @@ func (t *tracedP2PServer) GetNetInfo( return res, nil } -// tracedConfigServer decorates a ConfigServiceHandler with OpenTelemetry spans. +// tracedConfigServer decorates the config service handler with OpenTelemetry spans. type tracedConfigServer struct { inner v1connect.ConfigServiceHandler tracer trace.Tracer diff --git a/pkg/sequencers/single/queue.go b/pkg/sequencers/single/queue.go index 57ada8ab38..b767ec7fc2 100644 --- a/pkg/sequencers/single/queue.go +++ b/pkg/sequencers/single/queue.go @@ -465,7 +465,7 @@ func (bq *BatchQueue) Load(ctx context.Context) error { var legacyItems []queuedItem for result := range results.Next() { if result.Error != nil { - // a datastore read failure means the WAL cannot be trusted as + // A datastore read failure means the WAL cannot be trusted as // loaded — fail startup rather than silently dropping txs. return fmt.Errorf("failed to read WAL entry from datastore: %w", result.Error) } diff --git a/pkg/service/baseservice_test.go b/pkg/service/baseservice_test.go index e48afd326c..3524ef72c8 100644 --- a/pkg/service/baseservice_test.go +++ b/pkg/service/baseservice_test.go @@ -10,7 +10,7 @@ import ( "github.com/rs/zerolog" ) -// dummyService is a simple implementation of the Service interface for testing purposes. +// dummyService is a simple implementation of Service for testing purposes. type dummyService struct { *BaseService runCalled bool