acaudwell / Gource

software version control visualization
https://gource.io
GNU General Public License v3.0
11.55k stars 723 forks source link

Made no-time-travel more robust. #179

Closed SmallLars closed 5 years ago

SmallLars commented 6 years ago

Avoid two commits with the same timestamp when using no-time-travel. Since 5ec56acb this helps to avoid cancelling a file removal.

I never had the issues this change try to avoid. But while I was thinking about the last changes this situation came in my mind.

SmallLars commented 6 years ago

Any comments? :D

acaudwell commented 5 years ago

Thanks for raising the potential issue. I was wondering if there was a better way to do this without altering the timestamps but I haven't come up with anything yet.

SmallLars commented 5 years ago

Hmmm... Maybe you can accept this change? I think it would be good as long as there is no other way.

acaudwell commented 5 years ago

I'll try to revisit this next week.

acaudwell commented 5 years ago

Hi Lars. Sorry it's taken me a while to try and get my head around this again.

I think I have another solution f9a887280051877b74638d7b3f0a4fddce6009e5 . This wraps the original code you identified as causing the undesirable time travel behavior without changing commit timestamps. Does this seem reasonable?

SmallLars commented 5 years ago

Thank you, that seems reasonable, yes. When I tested this change, I also paid attention to deleted files that may be preserved in the visualization. Fortunately I could not recognize any. Works for me :D