Created
April 10, 2019 11:20
-
-
Save knocte/6021bcb5e5e6d5d217155848109f6a6a to your computer and use it in GitHub Desktop.
isCancelled assertion
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/GWallet.Backend/FaultTolerantParallelClient.fs b/src/GWallet.Backend/FaultTolerantParallelClient.fs | |
index 32bbe9b..3769a05 100644 | |
--- a/src/GWallet.Backend/FaultTolerantParallelClient.fs | |
+++ b/src/GWallet.Backend/FaultTolerantParallelClient.fs | |
@@ -150,6 +150,8 @@ type FaultTolerantParallelClient<'K,'E when 'K: equality and 'E :> Exception>(up | |
let taskToWaitForFirstFinishedTask = Task.WhenAny theTasks | |
let! fastestTask = Async.AwaitTask taskToWaitForFirstFinishedTask | |
+ if fastestTask.IsCanceled then | |
+ return failwith "it's canceled, shit" | |
let failuresOfTask,resultOfTask = fastestTask.Result | |
let restOfTasks: List<Task<NonParallelResults<'K,'R,'E>>> = |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment