Sync status of disconnected peers not up to date

I have noticed some behaviour I didn’t expect to see.

Suppose three devices A, B, C, all with folders in common.

In my set up, A is an introducer and all peers have accepted all other peers folders.

Ok, so suppose B and C are mostly offline (mobile phones), and is running for only a few minutes each hour, but A is always online.

B has local changes, and syncs with A. Devices B thinks A is up to date, but C is not (because C is offline). Device B goes offline. This all makes sense.

Now C comes online, having last seen B before B had local changes. C pulls the changes from A, but now claims that B is out of date.

Now, this makes sense, because as far as C knows, the state of B is still earlier than the state of A.

My question is, is this a bug? or working as intended?

If working as intended, then, as an improvement, is it possible for device C to query device A for last known state of device B?

If the peers query each other and accept the most recent state of a disconnected peer, then this would make the sync status of disconnected peers more accurate and more intuitive to me.

A disconnected peer should only show as out-of-date if the most recent state known is not up-to-date for the folder.

I’ve only noticed this behaviour since the sync status was added to the mobile app device status. This happened only a month or so ago. Full disclosure, I’m running syncthing-fork and not official syncthing on my android devices. But on the always on device, I’m running latest syncthing from the syncthing repo.

Yes, that is an expected corner case. We only know the state from the last direct connection. There is no mechanism to convey other devices’ status to third parties as far as I know, so this is unlikely to get “fixed”.

I recently noted this in the related pull request discussion, but so far no consensus how to go forward. In fact, the information has traditionally been missing from the GUI for exactly this reason, because it is possibly misleading / wrong. That might be the better option to avoid this expected confusion in the future.

1 Like

Thanks for the quick response and clarification.

Yes, only since the device status was shown in the UI did I become concerned.

I never noticed any actual issues with things not being in sync due to my setup.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.