[Unison-hackers] On making times=true the default
Tõivo Leedjärv
toivol at gmail.com
Thu Jan 16 04:35:51 EST 2025
TL;DR I'd like to get your opinions and ideas on two questions: 1) Do
you think times=true should be the default? 2) If yes, any suggestions
on how to manage existing users?
https://urldefense.com/v3/__https://github.com/bcpierce00/unison/issues/1074__;!!IBzWLUs!WDM4SbJXv90z9sL7gkUlmFoyUzgAVrxWJ-lwNbcpNLmPalnh94VzQXcjZN5K4XEfs4YIzs2MtbfdvOnkmGByBu2n4xo$
Currently the times preference (syncing file modification times)
defaults to off. There have been several suggestions that it should
default to on, and I agree. Since it looks like another major release
is near, now is a good time to once again consider making times=true
the default.
I think the main counter-arguments have been two-fold:
1) FAT filesystems may cause trouble. How real is this issue? Would
there be trouble (if at all) only at DST changes or any time?
2) Existing users would get a nasty surprise as potentially their
entire replicas would be listed as conflicts due to different
mtimes.
I don't know how serious the issue with FAT filesystems is, but is it
sufficient to dictate a default preference for everyone? Likely not.
As for managing the change for existing users, I'm thinking the solution
might be to earmark all the archives that are created after this change
of default. Then, when loading archives without this mark, and the user
hasn't specified the times preference, we'd set times=false again. This
way, all the new users will get the new default, all the existing users
will not get a nasty surprise, and all users explicitly setting the times
preference won't be affected either way.
Finally, will this new default cause too much confusion? While I think
it would be the correct default, and should work well for hopefully
most users, it comes with a risk of confusing and frustrating users in
some specific situations.
Whenever a user starts syncing two new already-populated replicas, or
re-creates some existing archives (either by choice or by having lost
their archives), they may still get a ton of conflicts. This, I hope,
is acceptable because they can then explicitly set times=false if they
wish. When creating new archives and noticing many props conflicts,
Unison could even display a message hinting the user about this
preference.
I would welcome your opinions and ideas.
More information about the Unison-hackers
mailing list