question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

board.Refresh() generate an TypeInitializationException for 'Manatee.Trello.Json.DefaultJsonSerializer'

See original GitHub issue

Hello

I restarted my application since 2020, and I have now an error when executing this code:

_factory = new TrelloFactory();
_board = _factory.Board(TodoBoardId);
AsyncHelper.RunSync(() => _board.Refresh());

I get the following exception at : _board.Refresh()

System.TypeInitializationException : Une exception a été levée par l'initialiseur de type pour 'Manatee.Trello.Json.DefaultJsonSerializer'.
   at Manatee.Trello.Internal.DataAccess.JsonRepository.ValidateResponse(IRestResponse response)
   at Manatee.Trello.Internal.DataAccess.JsonRepository.<ProcessRequest>d__7`1.MoveNext()
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Manatee.Trello.Internal.DataAccess.JsonRepository.<Execute>d__1`1.MoveNext()
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Manatee.Trello.Internal.Synchronization.SynchronizationContext`1.<GetData>d__16.MoveNext()
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Manatee.Trello.Internal.Synchronization.DeletableSynchronizationContext`1.<GetData>d__7.MoveNext()
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Manatee.Trello.Internal.Synchronization.SynchronizationContext`1.<GetBasicData>d__20.MoveNext()
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Manatee.Trello.Internal.Synchronization.SynchronizationContext.<Synchronize>d__22.MoveNext()
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
   at TimeTracking.AsyncHelper.RunSync(Func`1 func) in C:\Users\EFD3\source\repos\TimeTracking\TimeTracking\AsyncHelper.cs:line 25
   at TimeTracking.Trello.TrelloService..ctor() in C:\Users\EFD3\source\repos\TimeTracking\TimeTracking\Trello\TrelloService.cs:line 47
   at TimeTracking.Main.<InitializeServices>b__5_0() in C:\Users\EFD3\source\repos\TimeTracking\TimeTracking\Main.cs:line 65
   at TimeTracking.Main.loadingBackgroundWorker_DoWork(Object sender, DoWorkEventArgs e) in C:\Users\EFD3\source\repos\TimeTracking\TimeTracking\Main.cs:line 152

I have the following NuGet packages installed Manatee.Trello : 4.1.1 Manatee.Json : 12.0.2

I don’t know if it is a change at Trello level. My app was working well in 2019, end of December. I don’t know if there is a link…

I can provide you an extract of my application if you want.

Best regards

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6

github_iconTop GitHub Comments

1reaction
arobasse2commented, Jan 8, 2020

Hello and sorry for late response, time zone difference.

Thank a lot for your investigation, it successfully solve my problem. I forgotten I had made an upgrade of Manatee.Json…

Thank again for your work on those libs Have a nice new year. Bye

0reactions
gregsdenniscommented, Jan 22, 2020

I’ve updated to Manatee.Json 12. Please see v4.2.1.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Json.Serialization exception · Issue #279
Rethrow as TargetInvocationException: Exception has been thrown by the target of an invocation. Manatee.Trello.Internal.DataAccess.
Read more >
Rest api not working after the last major trello update
I have a web application that uses the rest api (through manatee.trello wrapper -> https://github.com/gregsdennis/Manatee.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found