Skip to content

Commit

Permalink
Let cancelled exception bubble up
Browse files Browse the repository at this point in the history
  • Loading branch information
ManlyMarco committed Apr 24, 2020
1 parent 69ebcdd commit dcd3cd5
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion KKManager.Updater/Windows/ModUpdateProgressDialog.cs
Original file line number Diff line number Diff line change
Expand Up @@ -232,11 +232,16 @@ private async Task<bool> UpdateSingleItem(IGrouping<string, Tuple<UpdateInfo, Up
if (source.Item2.RemoteFile is ZipUpdater.ArchiveItem)
labelPercent.Text = $"Extracting... Overall progress: {_completedSize} / {_overallSize}.";

await RetryHelper.RetryOnExceptionAsync(() => source.Item2.Update(progress, _cancelToken.Token), 3, TimeSpan.FromSeconds(3), _cancelToken.Token);
await RetryHelper.RetryOnExceptionAsync(() => source.Item2.Update(progress, _cancelToken.Token), 3,
TimeSpan.FromSeconds(3), _cancelToken.Token);

ex = null;
break;
}
catch (OperationCanceledException)
{
throw;
}
catch (Exception e)
{
Console.WriteLine($"Marking source {source.Item1.Source.Origin} as broken because of exception: {e.ToStringDemystified()}");
Expand Down

0 comments on commit dcd3cd5

Please sign in to comment.