Skip to content

light: add case to catch cancelled contexts within the detector#6701

Merged
cmwaters merged 3 commits intomasterfrom
callum/light-contexts-2
Jul 14, 2021
Merged

light: add case to catch cancelled contexts within the detector#6701
cmwaters merged 3 commits intomasterfrom
callum/light-contexts-2

Conversation

@cmwaters
Copy link
Copy Markdown
Contributor

Missed a case from #6687 which appeared in a e2e testnet.

I've also added some tests but I'll admit that I'm unsure if there's perhaps a better way to test context handling.

@cmwaters cmwaters requested a review from alexanderbez July 13, 2021 15:49
@codecov
Copy link
Copy Markdown

codecov bot commented Jul 13, 2021

Codecov Report

Merging #6701 (9d913f3) into master (36a859a) will increase coverage by 0.07%.
The diff coverage is 50.00%.

@@            Coverage Diff             @@
##           master    #6701      +/-   ##
==========================================
+ Coverage   60.83%   60.90%   +0.07%     
==========================================
  Files         297      297              
  Lines       28227    28229       +2     
==========================================
+ Hits        17172    17194      +22     
+ Misses       9319     9304      -15     
+ Partials     1736     1731       -5     
Impacted Files Coverage Δ
light/detector.go 76.30% <50.00%> (-0.90%) ⬇️
internal/p2p/pex/reactor.go 79.80% <0.00%> (-2.96%) ⬇️
internal/p2p/switch.go 61.81% <0.00%> (-1.82%) ⬇️
internal/evidence/reactor.go 66.39% <0.00%> (-1.64%) ⬇️
internal/consensus/wal.go 59.00% <0.00%> (-1.25%) ⬇️
proxy/multi_app_conn.go 48.05% <0.00%> (ø)
internal/consensus/state.go 67.41% <0.00%> (+0.27%) ⬆️
internal/consensus/peer_state.go 79.38% <0.00%> (+0.43%) ⬆️
internal/statesync/reactor.go 57.64% <0.00%> (+0.50%) ⬆️
internal/p2p/conn/connection.go 79.12% <0.00%> (+0.54%) ⬆️
... and 7 more

@cmwaters cmwaters added the S:backport-to-v0.34.x Tell mergify to backport the PR to v0.34.x label Jul 14, 2021
@cmwaters cmwaters merged commit 40fba39 into master Jul 14, 2021
@cmwaters cmwaters deleted the callum/light-contexts-2 branch July 14, 2021 09:23
mergify bot pushed a commit that referenced this pull request Jul 14, 2021
(cherry picked from commit 40fba39)

# Conflicts:
#	light/detector.go
#	light/provider/mock/mock.go
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S:backport-to-v0.34.x Tell mergify to backport the PR to v0.34.x

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants