Re: False positives in git diff-index
On Wed, Jan 5, 2011 at 06:15, Jeff King <peff@peff.net> wrote:
> On Wed, Jan 05, 2011 at 06:07:35AM +0000, Alexander Gladysh wrote:
>> > But using that script, I can't replicate your problem. Can you try
>> > running it on the same box you're having trouble with? That might at
>> > least tell us if it's your environment or something more complex going
>> > on.
>> Thank you. I tried it, and, unfortunately, it does not reproduce the
>> problem.
> Oh well, thanks for trying.
> Going back to your original reproduction recipe, can you change the
> "diff-index" line to actually report on what it thinks is different?
> That is, drop the "--quiet" and have it actually produce a patch?
----> Rebuilding manifest... Making manifest for . Generating index.html for . :100644 100644 483a7292436daecc9bea0ab265ee19d587b14298 0000000000000000000000000000000000000000 M cluster/localhost-ag/rocks/index.html :100644 100644 fcb9ff896fd1a1bd15663fa9be19b250789d4a25 0000000000000000000000000000000000000000 M cluster/localhost-ag/rocks/manifest
These are the two files, which are overridden with identical content. (See below, looks like I realized who to blame.)
If I read this correctly, Git tells me that the files are deleted. No?
Anyway, I checked, looks like that files are overridden (by fopen("name", "w")), never explicitly deleted. If it is important, I will checkout strace.
Contunuing with the script:
----> Comitting changed manifest... 2edcbfabc11f9bbab4fc8c059490cba9ae196d27 # On branch ag/git-debugging # Changed but not updated: # (use "git add <file>..." to update what will be committed) # (use "git checkout -- <file>..." to discard changes in working directory) # # typechange: cluster/localhost-ag/versions/versions-current.lua # no changes added to commit (use "git add" and/or "git commit -a")
Suddenly: no changes.
> It would be interesting to see what is different, and how that compares
> with the "git status" you run just prior to it (and whether it matches
> the file you "git add"ed just above).
Git status before:
$ git status # On branch ag/git-debugging # Changed but not updated: # (use "git add <file>..." to update what will be committed) # (use "git checkout -- <file>..." to discard changes in working directory) # # typechange: cluster/localhost-ag/versions/versions-current.lua # no changes added to commit (use "git add" and/or "git commit -a")
> You haven't told us much about your build process. Are you absolutely
> sure that there couldn't be another process on the system manipulating
> the files between the various runs?
No other process. But see below.
> Are you running on top of any special filesystem that might not meet the
> consistency guarantees we expect (though in that case, I would assume my
> trivial script would have reproduced).
And here I have to say "Oops".
My apologies, I should have realized this before: my project is mounted on VMWare's HGFS.
(That is: VMWare Fusion Ubuntu Guest -> HGFS -> OS X 10.6 Host files.)
The problem is not reproduced if I copy the project to the native fs in the guest machine.
But the problem is also not reproduced if I execute your script on the HGFS.
So, does that mean that HGFS violates consistency guarantees?
Alexander.