Skip to content

Commit

Permalink
Moar lint 🤦
Browse files Browse the repository at this point in the history
Signed-off-by: Cyril Tovena <[email protected]>
  • Loading branch information
cyriltovena committed Nov 4, 2020
1 parent ccbb0eb commit d1b856c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 2 additions & 0 deletions pkg/ingester/checkpoint.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import (
)

// The passed wireChunks slice is for re-use.
// nolint(deadcode)
func toWireChunks(descs []*chunkDesc, wireChunks []Chunk) ([]Chunk, error) {
if cap(wireChunks) < len(descs) {
wireChunks = make([]Chunk, len(descs))
Expand Down Expand Up @@ -38,6 +39,7 @@ func toWireChunks(descs []*chunkDesc, wireChunks []Chunk) ([]Chunk, error) {
return wireChunks, nil
}

// nolint(deadcode)
func fromWireChunks(conf *Config, wireChunks []Chunk) ([]*chunkDesc, error) {
descs := make([]*chunkDesc, 0, len(wireChunks))
for _, c := range wireChunks {
Expand Down
3 changes: 2 additions & 1 deletion pkg/ingester/encoding_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@ import (
"testing"
"time"

"github.com/grafana/loki/pkg/logproto"
"github.com/prometheus/prometheus/pkg/labels"
"github.com/prometheus/prometheus/tsdb/record"
"github.com/stretchr/testify/require"

"github.com/grafana/loki/pkg/logproto"
)

func Test_Encoding_Series(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion pkg/ingester/transfer.go
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ func (i *Ingester) transferOut(ctx context.Context) error {
return err
}

chunks := make([]*logproto.Chunk, 1, 1)
chunks := make([]*logproto.Chunk, 1)
chunks[0] = &logproto.Chunk{
Data: bb,
}
Expand Down

0 comments on commit d1b856c

Please sign in to comment.