This has bothered me for many years. This thread didn't solve it, but it did help me observe what was happening, at least in my case.
I notice this most often when I am renaming many files. Like I want to add the word "lecture" in front of 20 files.
What I observed is that in my OneDrive files,
- As soon as I change the name of File 1, it resyncs that file. That takes about 2 seconds.
- But after 1 second, I am already renaming the File 2.
- When File 1 completes the sync, Windows seems to reset the folder which means it selects the entire file name for me in File 2, while I am half-done editing. Annoying!
What I noticed is that if I wait 2 seconds for File 1 to complete its sync, and then select File 2, then Windows does not reset the folder while I am editing File 2 and the problem goes away.
Of course this is also annoying, to wait 2 seconds (or longer for large files) for the previous file to sync before starting the next, in what was supposed to be a fast repetitive task.
So what I did instead was close OneDrive. Then the syncs stay pending. I edit all file names, and then turn OneDrive back on to complete the syncs. That worked for me, or has so far. I have not tested other scenarios yet.