diff --git a/internal/domain/watcher_test.go b/internal/domain/watcher_test.go index 8aeec4e..b4c2121 100644 --- a/internal/domain/watcher_test.go +++ b/internal/domain/watcher_test.go @@ -25,6 +25,7 @@ func TestWatcherKeywordMatches(t *testing.T) { } for scenario, tc := range tt { + tc := tc t.Run(scenario, func(t *testing.T) { t.Parallel() diff --git a/internal/reddit/client.go b/internal/reddit/client.go index 3b72d13..9ac7074 100644 --- a/internal/reddit/client.go +++ b/internal/reddit/client.go @@ -369,6 +369,7 @@ func (rac *AuthenticatedClient) request(ctx context.Context, r *Request, errmap return rh(val), nil } +//nolint:unparam func (rac *AuthenticatedClient) logRequest() error { if rac.redditId == SkipRateLimiting { return nil diff --git a/internal/worker/live_activities.go b/internal/worker/live_activities.go index 8c04578..aad5042 100644 --- a/internal/worker/live_activities.go +++ b/internal/worker/live_activities.go @@ -145,7 +145,7 @@ func (lac *liveActivitiesConsumer) Consume(delivery rmq.Delivery) { key := fmt.Sprintf("locks:live-activities:%s", at) // Measure queue latency - ttl := lac.redis.TTL(lac, key).Val() + ttl := lac.redis.PTTL(lac, key).Val() age := (domain.NotificationCheckTimeout - ttl) _ = lac.statsd.Histogram("apollo.dequeue.latency", float64(age.Milliseconds()), []string{"queue:live_activities"}, 0.1)