I can't sync with my OneDrive at the first-time

If this is a bug report, please create it on GitHub instead. Follow this link:

on

Operating system

Android

Joplin version

3.5.8

Sync target

OneDrive

What issue do you have?

I created a note in joplin on my computer and successfully synced it to OneDrive, but when I tried to sync it on the Android client, the in-app page prompted me to log in to the incorrect account.

Screenshots

See Sync with OneDrive on Android use - #13 by mrjo118 . Some people seem to be getting Microsoft account specific issues when syncing new Joplin client setups with OneDrive lately.

Not likely you can resolve this with Microsoft directly, so the only guaranteed solution (if you want to continue using OneDrive sync) is creating a brand new Microsoft account and importing your data into a fully reset Joplin client (but you could try revoking access first, and see if that helps resolve the issue)

I discovered something interesting during the repair process that I hope will be helpful:

I removed OneDrive's access permissions to joplin and then deleted the corresponding folder in OneDrive. During the fresh sync, I noticed the directory structures were different. In the previous sync directory, there were two folders: apps-graph and apps-designer. The new sync directory no longer has the graph & designer folders; all files are now in apps-joplin.

I hope this is useful. Thank you.

That is useful, thank you! At least now we know the root cause and a fix without having to create a new Microsoft account. Looks like Microsoft is either messing about with their API users, or they have another intermittent bug like this one Sychronizing to OneDrive creates \Apps\Graph folder · Issue #11489 · laurent22/joplin · GitHub

Hello, I tried some methods based on the answer you cited. This included logging into a newly created Microsoft account on a phone with Joplin newly installed, an account that hadn't previously authorized Joplin.

Unfortunately, it still didn't work, so I believe this isn't your problem. I will contact Microsoft support and will get back to you if I have any updates. Thank you very much for your help~

That is not good news. I too have now created a new Microsoft account and was able to reproduce the issue. The interesting thing is that this only happens on Android. I was able to connect properly to the account using the Windows app.

I have to say though, even on the working client, the sync is much slower than it used to be. Uploading items is now even slower than Dropbox.

I don’t see any change to the folder which is created on OneDrive though, it still goes the Apps/Joplin which is how it’s always been:

EDIT: I also retested this with my existing Microsoft account, and I get the error on Android as well

Yes, sir, I synchronized 200 MB of files in 4 hours in the test this day,Maybe we can only wait for Microsoft to do something. I submitted this issue to Microsoft account support today, but so far there has been no reply.

I have also created a Joplin issue here Mobile: It is no longer possible to authenticate new device / profiles with OneDrive sync · Issue #14727 · laurent22/joplin · GitHub

Maybe Microsoft have made an unpublished change to their API / authentication method

2 Likes

The root cause of the authentication issue has been identified Mobile: It is no longer possible to authenticate new device / profiles with OneDrive sync · Issue #14727 · laurent22/joplin · GitHub

It sounds to me that the format of the auth token has changed slightly, and the encoding / decoding behaviour is inconsistent on the mobile app. The good news is this is fixable on the Joplin side, so I expect we will have a fix soon and Joplin 3.5 will get a patch for this

3 Likes

Thank you again for your efforts. I will wait for the Android version update.

This is now fixed in Joplin 3.6.14. Not sure now if there will be a 3.5 patch, but you can download the prerelease with the fix here: Release android-v3.6.14 · laurent22/joplin-android · GitHub

3 Likes

Thank you, I will try this version now

I encounter exactly the same issue on iOS. Will the iOS have new version to fix this issue as well?

@Blucy Can you confirm, did the new release fix the issue?

I have the same issue on Android.

I use both Android and iOS and it works fine on my iPhone. Is the auth method different on both devices?

@hiwyx Can you try installing the prerelease on Android?

3.6.14 works! Thanks!