m-lab / traceroute-caller

A sidecar service which runs traceroute after a connection closes
Apache License 2.0
18 stars 5 forks source link

Make golangci-lint pass. #99

Closed SaiedKazemi closed 3 years ago

SaiedKazemi commented 3 years ago

This change is Reviewable

SaiedKazemi commented 3 years ago

Notice that this PR should be merged after PR #97.

coveralls commented 3 years ago

Pull Request Test Coverage Report for Build 185


Changes Missing Coverage Covered Lines Changed/Added Lines %
tracer/scamper.go 4 6 66.67%
<!-- Total: 11 13 84.62% -->
Totals Coverage Status
Change from base Build 179: -0.3%
Covered Lines: 607
Relevant Lines: 609

💛 - Coveralls
SaiedKazemi commented 3 years ago

tracer/scamper.go, line 191 at r3 (raw file):

Previously, gfr10598 (Gregory Russell) wrote…
Hmm - I'm guessing that the previous code was actually buggy - race with value of c changing and goroutine capturing it.

Huh :)

SaiedKazemi commented 3 years ago

tracer/scamper_test.go, line 385 at r3 (raw file):

Previously, gfr10598 (Gregory Russell) wrote…
It is unfortunate to remove these, as they perform a compile time check. If necessary, we can invoke this from an init() function in the test file to avoid warnings. I guess this linter doesn't have any way to ignore specific lines/warnings?

Since assertScamperDaemonIsTracer() isn't used and can be deleted, it is OK to delete the comment lines above it.