-
Type: Story
-
Status: Resolved (View Workflow)
-
Priority: Medium
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: NEM
-
Labels:None
-
Story Points:3
-
Epic Link:
Resolve any errors reported by "make lint"
root@ip-10-5-1-11:~/cord/device-management# make lint
Running style check...
Style check OK
Running Dockerfile lint check ...
Dockerfile lint check OK
Running sanity check...
Sanity check OK
Running dependency check...
all modules verified
Dependency check OK
root@ip-10-5-1-11:~/cord/device-management#
to fix this did following things
- to fix lint-dockerfile excluded vendor directory
- to fix lint-style had execute go fmt on most files
- to fix lint-sanity fixed following errors and generated pb.go file and recompiled demotest
root@ip-10-5-1-11:~/cord/device-management# make lint-sanity
Running sanity check...
- github.com/opencord/device-management
./main.go:77:2: Println arg list ends with redundant newline
./main.go:96:2: Println arg list ends with redundant newline
./main.go:109:2: Println arg list ends with redundant newline
./main.go:136:2: Println arg list ends with redundant newline
./main.go:171:2: Println arg list ends with redundant newline
./main.go:269:14: Printf call has arguments but no formatting directives
./main.go:365:2: Println arg list ends with redundant newline
./main.go:391:3: Println call has possible formatting directive %v
./main.go:397:3: Println call has possible formatting directive %v
- github.com/opencord/device-management/demo_test
demo_test/test.go:54:2: Println arg list ends with redundant newline
demo_test/test.go:76:3: Error call has possible formatting directive %s
demo_test/test.go:86:5: Error call has possible formatting directive %s
demo_test/test.go:88:5: Info call has possible formatting directive %s
demo_test/test.go:132:3: Fatal call has possible formatting directive %v
demo_test/test.go:139:3: Fatal call has possible formatting directive %v
demo_test/test.go:144:3: Fatal call has possible formatting directive %v
Makefile:102: recipe for target 'lint-sanity' failed
make: *** [lint-sanity] Error 2
root@ip-10-5-1-11:~/cord/device-management#