From 2ef281086c9f540b1a90d3883898b7c58716a4e2 Mon Sep 17 00:00:00 2001 From: Sam Catlow Date: Wed, 23 Sep 2026 03:33:32 +1000 Subject: [PATCH] chore(fmt): adopt go fix's range-over-int in two loops task check's fmt pass rewrites both, so the committed tree was not fmt-canonical. Adopted verbatim, per the repository's rule that formatting changes from the configured formatter are law. --- internal/infrastructure/artifactsync/sender.go | 2 +- internal/store/store_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/infrastructure/artifactsync/sender.go b/internal/infrastructure/artifactsync/sender.go index c3fee3ae4..b46d0f3c8 100644 --- a/internal/infrastructure/artifactsync/sender.go +++ b/internal/infrastructure/artifactsync/sender.go @@ -112,7 +112,7 @@ func (c *Client) Publish(ctx context.Context, a Artifact) (string, error) { const attempts = 4 // the initial attempt plus three retries var lastErr error - for attempt := 0; attempt < attempts; attempt++ { + for attempt := range attempts { if attempt > 0 { select { case <-ctx.Done(): diff --git a/internal/store/store_test.go b/internal/store/store_test.go index 6d8425cd7..aa3e770f5 100644 --- a/internal/store/store_test.go +++ b/internal/store/store_test.go @@ -553,7 +553,7 @@ func TestEventsSincePagesIdenticalTimestampsWithoutSkipOrRepeat(t *testing.T) { at := time.Date(2026, 1, 1, 0, 0, 0, 0, time.UTC) const total = 50 inserted := make(map[int64]string, total) - for i := 0; i < total; i++ { + for i := range total { detail := fmt.Sprintf("event-%d", i) id, err := s.InsertEvent(ctx, events.Event{Kind: "log", At: at, Detail: detail}) if err != nil {