How to deal with duplicate files created by sync

I’m using Obsidian sync, and 99% of the time it works great, but every once in a will it will create a duplicate of a file, presumably because there was some conflict in the file that it couldn’t resolve. That’s fine; I’d prefer that to a bad merge that might lose data.

But my problem is that these sync conflicts seem to happen silently, and I don’t notice them until I happen to run across “My note 1” in my vault, possibly weeks or months later. (I just did a search and found a few really old ones that I never knew about.) Then I cringe and diff the versions and try to understand which is newer and what changes I made, and hope that I didn’t somehow edit both versions of the file at different times; and clean up links — for some reason the links always point to the “1” version of the file, so I have to go back and change them all.

How do other folks deal with this? At a minimum, is there a way to know about conflicts when they happen? I was debating writing a plugin to tell me when these conflict files appear, but that seems overboard to fix a problem that the base product should probably already be addressing.

Obsidian Sync does not create conflict files, it’s not programmed to do so.
Some other (sync) tool creates those.

Well, now I’m flummoxed. I’m definitely not using another sync tool, and I have a very short list of plugins, none of which seem in any way related.

Maybe it’s not related to conflicts — in fact, some of the duplicated files were exactly the same, which makes it seem like a conflict is unlikely. Is there any other feature in Obsidian that might be duplicating files. It’s got to be something in Obsidian because it not only creates the new file but also updates all the links to point to it.

Doing a little digging into the sync history for some of the affected files, it looks like this tends to happen around when I rename a file. Obviously it doesn’t happen consistently, but maybe that’s a clue.

  • You can post your “Show Debug Info” and maybe someone can spot a suspicious plugin. And then we’ll also know key info like your OS and Obsidian installer version.
  • Are you sure you aren’t using another syncing tool? In MacOS some default folders automatically sync with iCloud. In Windows, some default folders automatically sync with OneDrive. When installing some cloud tools, they “helpfully” offer to backup other folders.

Perhaps. Again, the plugin list from “Show Debug Info” will help here.

Sure, here’s my debug info:

SYSTEM INFO:
Obsidian version: v1.5.12
Installer version: v1.5.12
Operating system: Windows 10 Enterprise 10.0.22631
Login status: logged in
Catalyst license: insider
Insider build toggle: off
Live preview: on
Base theme: dark
Community theme: none
Snippets enabled: 2
Restricted mode: off
Plugins installed: 6
Plugins enabled: 5
1: Calendar v1.5.10
2: Timeline v1.1.0
3: Dataview v0.5.66
4: List Callouts v1.2.7
5: Ninja Cursor v0.0.13

RECOMMENDATIONS:
Custom theme and snippets: for cosmetic issues, please first try updating your theme and disabling your snippets. If still not fixed, please try to make the issue happen in the Sandbox Vault or disable community theme and snippets.
Community plugins: for bugs, please first try updating all your plugins to latest. If still not fixed, please try to make the issue happen in the Sandbox Vault or disable community plugins.

Hi, just a ping to see if there are any other thoughts on this?

I had asked another question:

Did you carefully check your vault isn’t in a default OS path? Can you share the full path to your vault? (Hide your username or any sensitive info you don’t want to show.)

I’m on Windows, and I very intentionally made sure the vault wouldn’t be synced by anything else. I do use Dropbox and OneDrive, but obviously not on this path:

C:\repos\pkb\PKB