Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

golangci-lint errors #22

Open
ahrtr opened this issue Jun 7, 2024 · 1 comment
Open

golangci-lint errors #22

ahrtr opened this issue Jun 7, 2024 · 1 comment

Comments

@ahrtr
Copy link
Owner

ahrtr commented Jun 7, 2024

Running [/home/runner/golangci-lint-1.53.3-linux-amd64/golangci-lint run] in [/home/runner/work/etcd-diagnosis/etcd-diagnosis] ...
  Error: plugins/epstatus/plugin.go:58:35: ck.GlobalConfig undefined (type *epStatusChecker has no field or method GlobalConfig) (typecheck)
  	if eps, err = agent.Endpoints(ck.GlobalConfig); err != nil {
  	                                 ^
  Error: plugins/epstatus/plugin.go:75:73: ck.GlobalConfig undefined (type *epStatusChecker has no field or method GlobalConfig) (typecheck)
  			if chkResult.EpStatusList[i].EpStatus, err = agent.EndpointStatus(ck.GlobalConfig, ep); err != nil {
  			                                                                     ^
  Error: plugins/epstatus/plugin.go:113:29: ck.GlobalConfig undefined (type *epStatusChecker has no field or method GlobalConfig) (typecheck)
  	checkDBSize(&chkResult, ck.GlobalConfig)
  	                           ^
  Error: plugins/membership/plugin.go:53:35: ck.GlobalConfig undefined (type *membershipChecker has no field or method GlobalConfig) (typecheck)
  	if eps, err = agent.Endpoints(ck.GlobalConfig); err != nil {
  	                                 ^
  Error: plugins/membership/plugin.go:62:48: ck.GlobalConfig undefined (type *membershipChecker has no field or method GlobalConfig) (typecheck)
  		if memberLists[i], err = agent.MemberList(ck.GlobalConfig, []string{ep}, clientv3.WithSerializable()); err != nil {
  		                                             ^
  Error: plugins/metrics/plugin.go:66:35: ck.GlobalConfig undefined (type *metricsChecker has no field or method GlobalConfig) (typecheck)
  	if eps, err = agent.Endpoints(ck.GlobalConfig); err != nil {
  	                                 ^
  Error: plugins/metrics/plugin.go:84:39: ck.GlobalConfig undefined (type *metricsChecker has no field or method GlobalConfig) (typecheck)
  		allMetrics, err := agent.Metrics(ck.GlobalConfig, ep)
  		                                    ^
  Error: plugins/read/plugin.go:67:35: ck.GlobalConfig undefined (type *readChecker has no field or method GlobalConfig) (typecheck)
  	if eps, err = agent.Endpoints(ck.GlobalConfig); err != nil {
  	                                 ^
  Error: plugins/read/plugin.go:88:[28](https://github.com/ahrtr/etcd-diagnosis/actions/runs/9417024444/job/25941371734#step:4:30): ck.GlobalConfig undefined (type *readChecker has no field or method GlobalConfig) (typecheck)
  				_, err = agent.Read(ck.GlobalConfig, []string{ep}, "health")
  				                       ^
  Error: plugins/read/plugin.go:90:28: ck.GlobalConfig undefined (type *readChecker has no field or method GlobalConfig) (typecheck)
  				_, err = agent.Read(ck.GlobalConfig, []string{ep}, "health", clientv3.WithSerializable())
  				                       ^
  Error: ../../../../../opt/hostedtoolcache/go/1.21.11/x64/src/net/http/internal/chunked.go:79:14: undefined: max (typecheck)
  	cr.excess = max(cr.excess, 0)
  	            ^

@ahrtr
Copy link
Owner Author

ahrtr commented Jun 7, 2024

Only see this issue after bumping go version from 1.21.1 to 1.21.11.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant