chore: Forbids "log" package only for aggregators, inputs, outputs, parsers and processors (#10191)
Co-authored-by: Pawel Zak <Pawel Zak>
This commit is contained in:
parent
2269ff1242
commit
1143a50da3
|
|
@ -126,5 +126,10 @@ issues:
|
|||
- path: _test\.go
|
||||
text: "parameter.*seems to be a control flag, avoid control coupling"
|
||||
|
||||
- path: (^agent/|^cmd/|^config/|^filter/|^internal/|^logger/|^metric/|^models/|^selfstat/|^testutil/|^plugins/serializers/)
|
||||
text: "imports-blacklist: should not use the following blacklisted import: \"log\""
|
||||
linters:
|
||||
- revive
|
||||
|
||||
output:
|
||||
format: tab
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ package logrus
|
|||
|
||||
import (
|
||||
"io"
|
||||
"log"
|
||||
"log" //nolint:revive // Allow exceptional but valid use of log here.
|
||||
"strings"
|
||||
"sync"
|
||||
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ package shim
|
|||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"log"
|
||||
"log" //nolint:revive // Allow exceptional but valid use of log here.
|
||||
"os"
|
||||
|
||||
"github.com/BurntSushi/toml"
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ package shim
|
|||
|
||||
import (
|
||||
"fmt"
|
||||
"log"
|
||||
"log" //nolint:revive // Allow exceptional but valid use of log here.
|
||||
"os"
|
||||
"reflect"
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue