Error: Task Canceled when loading items by Caml query
See original GitHub issueI’m TaskCanceled exception on list.LoadItemsByCamlQuery(…).
In order to read “all” SharePoint data faster, I’m using different Task and split the work among them. Each of those tasks have own PnPContext (which can be reused for same Web if no other Task is using it). Error occurs on different ListItems.
StackTrace:
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.ConfiguredTaskAwaitable
1.ConfiguredTaskAwaiter.GetResult()
at PnP.Core.Services.BatchClient.<ExecuteSharePointRestBatchAsync>d__48.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.ConfiguredTaskAwaitable.ConfiguredTaskAwaiter.GetResult()
at PnP.Core.Services.BatchClient.<ExecuteBatch>d__36.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.ConfiguredTaskAwaitable1.ConfiguredTaskAwaiter.GetResult() at PnP.Core.Model.BaseDataModel
1.<RequestAsync>d__93.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.ConfiguredTaskAwaitable1.ConfiguredTaskAwaiter.GetResult() at PnP.Core.Model.SharePoint.List.<LoadItemsByCamlQueryAsync>d__164.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.GetResult() at PnP.Core.Model.SharePoint.List.LoadItemsByCamlQuery(CamlQueryOptions queryOptions, Expression
1[] selectors)`
Issue Analytics
- State:
- Created 2 years ago
- Comments:9 (6 by maintainers)
Top GitHub Comments
Let’s close for now @bajce , but feel free to either re-open or create a new one.
@jansenbe I was using the latest nightly version. Unfortunately not, I won’t have that much time soon to reproduce it in console application as it can take longer. I totally understand if you want to close the issue, once I have the console application which reproduces it I can reopen it (if possible) or create new one.