ipfs / go-bitswap

The golang implementation of the bitswap protocol
MIT License
216 stars 112 forks source link

Fix: Increment stats.MessagesSent in msgToStream() function #441

Closed wolneykien closed 4 years ago

wolneykien commented 4 years ago

See ipfs/go-bitswap#440.

wolneykien commented 4 years ago

When working on the branch I've once got the following error on CircleCI:

Failed
=== RUN   TestSessionBetweenPeers
    TestSessionBetweenPeers: bitswap_with_sessions_test.go:127: uninvolved nodes should only receive two messages 4
--- FAIL: TestSessionBetweenPeers (0.89s)

Locally, I've got the same error 6-9 times out of 16 runs in a row and for the master branch too. So I think that the test is unstable.

dirkmc commented 4 years ago

That test is flaky, created an issue: https://github.com/ipfs/go-bitswap/issues/442

dirkmc commented 4 years ago

Also thanks for refactoring to clean up the ipfs impl tests 💯

wolneykien commented 4 years ago

However, it seems there is another unstable test out there:

Failed
=== RUN   TestCancelOneRequestDoesNotTerminateAnother
    TestCancelOneRequestDoesNotTerminateAnother: providerquerymanager_test.go:174: Collected all peers on cancelled peer, should have been cancelled immediately
--- FAIL: TestCancelOneRequestDoesNotTerminateAnother (0.01s)
dirkmc commented 4 years ago

Added an issue for the flaky test: https://github.com/ipfs/go-libipfs/issues/88