Closed rbradford closed 5 years ago
LGTM
will hold on fixing up my patches until we fix this issue. Would be nice to get the CI green on them. @markdryan are you thinking along these lines? i also had an alternate patch that addressed this here. i liked @rbradford 's patch cause it was much more cleaner, but does either of those approaches tickle you? i personally like the commenting style, but i shall let you & @rbradford make the call.
@ganeshmaharaj The correct way to fix this is to explicitly discard all of the errors that do not need to be checked or cannot usefully be processed. This is what is done elsewhere in the code, e.g.,
https://github.com/intel/ccloudvm/blob/master/client/client.go#L176
I agree with @markdryan. Discarding the return value by assigning to _ is much nicer than dropping all fmt errors or the lint overrides.
The behaviour of errcheck has changed so that errors from the fmt package are no longer ignored. Restore the previous behaviour by overriding the errcheck linter syntax for gometalinter.
Signed-off-by: Rob Bradford robert.bradford@intel.com