Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not log TaskCanceledException as error #104

Closed
maybeec opened this issue Jan 19, 2016 · 2 comments
Closed

Do not log TaskCanceledException as error #104

maybeec opened this issue Jan 19, 2016 · 2 comments

Comments

@maybeec
Copy link

maybeec commented Jan 19, 2016

I think this should also not reported as an error to the user, shouldn't it?
Or does it cause any harm on synchronization?

I think the error was caused by shutting down my PC to StandyBy.

<?xml version="1.0" encoding="utf-16"?>
<SynchronizationReport xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <ProfileName>CalDAV</ProfileName>
  <ProfileId>31b1199f-ef4b-42f8-b097-d0c77e9e6555</ProfileId>
  <StartTime>2016-01-18T21:23:51.1131552Z</StartTime>
  <InitialEntityMatchingPerformed>false</InitialEntityMatchingPerformed>
  <LoadErrors />
  <EntitySynchronizationReports />
  <ExceptionThatLeadToAbortion>System.Threading.Tasks.TaskCanceledException: A task was canceled.
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
   at CalDavSynchronizer.DataAccess.HttpClientBasedClient.WebDavClient.&lt;ExecuteWebDavRequest&gt;d__a.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at CalDavSynchronizer.DataAccess.HttpClientBasedClient.WebDavClient.&lt;ExecuteWebDavRequestAndReadResponse&gt;d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at CalDavSynchronizer.DataAccess.CalDavDataAccess.&lt;GetEntities&gt;d__24.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
   at GenSync.Synchronization.Synchronizer`6.&lt;SynchronizeNoThrow&gt;d__4.MoveNext()</ExceptionThatLeadToAbortion>
  <Duration>08:51:39.2164937</Duration>
</SynchronizationReport>
@aluxnimm
Copy link
Owner

Well we can't distinguish if you lost your network or the server has some issues or a timeout, it won't do any harm and will be tried again with the next sync run of course. But maybe it could be a warning instead of an error yes.

@aluxnimm
Copy link
Owner

Finally we tried to improve this behaviour and log the first network errors only as warnings to avoid errors after startup from hibernate for example, will be in 2.19.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants