phw198 / OutlookGoogleCalendarSync

Sync your Outlook and Google calendars
https://www.outlookgooglecalendarsync.com/
Mozilla Public License 2.0
1.8k stars 215 forks source link

cant access google calender - 'Google.Apis.Json.NewtonsoftJsonSerializer' threw an exception #1407

Closed kalle8888 closed 2 years ago

kalle8888 commented 2 years ago

Hi, I used CS for quite a while but needed to reinstall, so I used the current USB version 2.9. When I try to set it up I get the following error after commit the calender request on google's website

Can anybody help. Thanks /Kalle

Authenticating with Google Preparing to authenticate with Google.

Unable to authenticate with Google. The following error occurred: The type initializer for 'Google.Apis.Json.NewtonsoftJsonSerializer' threw an exception. Could not load file or assembly 'Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=xxxxxxxxxxxxxxxxxx' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

Unable to get the list of Google calendars. The following error occurred:

Google handshake failed.

kalle8888 commented 2 years ago

I found the Bug...it is a Bug

I use the portable version without installation needed. The root directory of CalendarSync was in path names like this (using # signs) C:\##programms##\#tools'\CalendarSync.

After moving the dir to C:\CalendarSync it works

phw198 commented 2 years ago

As per OutlookGoogleCalendarSync.exe.config you can see the reference to Newtonsoft.Json is a local reference, not the entire path, so this wouldn't be something OGCS can fix - but at least you found the solution!

A bit odd though it's reporting version 10.0.0.0 - OGCS 2.9.0 uses v12.0 of Newtonsoft.Json...