Hi,
Whenever I sync files with windows, it shows the every binary file as modified. I've just cloned "fresh" repo from a linux host and git annex get
ed the 15-11-03 folder.
Running git annex status 15-11-03 shows
M ..\15-11-03/ADL Update 11-03-15.pptx
M ..\15-11-03/Gaming-Rage-Face.jpg
M ..\15-11-03/eluted-absorption-spectra.png
M ..\15-11-03/elution.png
M ..\15-11-03/prep-diagram.png
M ..\15-11-03/rc-elution-01 (2015 Nov 03).csv
M ..\15-11-03/rc-elution-02 (2015 Nov 03).csv
M ..\15-11-03/rc-elution-03 (2015 Nov 03).csv
M ..\15-11-03/rc-prep-01.h5
M ..\15-11-03/rc-test-1 (2015 Nov 03).csv
M ..\15-11-03/rc-test-2 (2015 Nov 03).csv
M ..\15-11-03/wash-absorption.png
Edit: I should add that this repo is untrusted. Doing sync on it just ends up pulling from remotes, not pushing anywhere:
λ git annex sync
commit (recording state in git...)
ok
pull origin
ok
pull github
ok
How would I check if this is a problem with my installation or a bug in git annex?
git annex status doesn't checksum files, so it can't be the sha executables in PATH.
Instead, git-annex status, when in a direct mode repository like on windows, checks the recorded timestamps etc of the files to determine if they're modified.
I suppose one possibility is a time zone change or DST change. Did you recently "fall back" from DST in your location?
Due to the braindead way Windows deals with timezone changes, the timestamps of files appear to change when the timezone has changed. git-annex tries to detect this situation and offset to get back a stable timestamp that can be used to detect file modifications, but I can't say that I've tested this situation very carefully, beyond the one very painful day implementing that workaround.
Anyway, running
git annex sync
may result in it noticing that nothing has actually changed and get the status display to work better.Aloukian were you able to get anything to help? Nothing I've tried has helped.
Joey any more ideas (besides ditching windows )?
Sorry I haven't had a chance to think about this problem any more. The v6 repository format I've been working on should eliminate class problem anyway. It will let git itself be able to tell if annexed files are modified or not.
But there is something you can try to debug what's going on.
cat .git/annex/sentinal.cache
and paste its content.stat .git/annex/sentinal --terse
and paste the output of that.stat $file --terse
and paste the output of that.cat $(git annex find $file --format='.git/annex/objects/${hashdirlower}${key}/${key}.cache
)But hmm, as I was running windows to get these instructions, I seem to have reproduced the problem myself! In my case:
git annex status
showed the file as modifed;git annex sync
found nothing to commit and didn't change that.Some more debugging and.. It seems this is not a horrible windows-specific time zone problem. Thank goodness. Instead, what's going on is that
git -c core.bare=false status
does not show these files as typechanged, but as modified instead. Sincegit annex status
only has special case handling for typechanged files, it just passes the M through and displays it.So, this is only a display problem, and thus nothing to worry about really. Ie, the rest of git-annex's behavior should not be impacted at all.
It's not windows specific.. Same happens on FAT on Linux. I think git's behavior probably changed since an earlier version; I'm pretty sure its status showed typechanged before. Anyway, I've fixed the status display, on these systems it will now treat files git says are modified the same as typechanged, and so will use git-annex's inode cache info to diplay an accurate status for them.
version 6.20160114 fixes the problem on windows and status seems to be faster now (probably due to all the overhead of printing text to the console).
Thanks!