This repository was archived by the owner on Jun 28, 2022. It is now read-only.
This repository was archived by the owner on Jun 28, 2022. It is now read-only.
Open
Description
After running with the -fix
option, the linter rewrites the import paths,
diff --git internal/k8s/log.go internal/k8s/log.go
index 8a6974fc..73899219 100644
--- internal/k8s/log.go
+++ internal/k8s/log.go
@@ -24,7 +24,7 @@ import (
"strings"
"github.com/sirupsen/logrus"
- klog "k8s.io/klog/v2"
+ klog_v2 "k8s.io/klog/v2"
)
type klogParams struct {
But all the symbols that are used from that package are still using the old import path. It's left to the maintainer to update each file that gets it import paths fixed.
This is OK for the CI use case since the goal there is to give automated style feedback to contributors (it's not too onerous for them to fix it by hand). It's a bit more onerous to get the existing codebase up to standard, but that's a one time cost.
So we could rewrite all the symbols, but if it's a lot of extra AST work, it might not be worth the effort.