Re: Regular Rebase Failure
- From
Stefan Beller <sbeller@google.com>
- Date
- Apr 21, 2015, 17:51 UTC
- Message-ID
- <CAGZ79kadXgsdCLH-YFQ5RhyKbRv9-qmUOQo-9QkKM2=8p17j+g@mail.gmail.com>
- In-Reply-To
- <553685E0.8010304@gmail.com>
On Tue, Apr 21, 2015 at 10:16 AM, Adam <adamgsteel@gmail.com> wrote:
> About two weeks ago I started getting a regular rebase failure. I get this > error several times a day and at least once a day I lose work to it.
Which git version are you using?
> --- > fatal: Unable to create '/Users/asteel/path/to/repo/.git/index.lock': File > exists.
Searching through the code base there are only 3 occurrences of "Unable to create" matching the capitalization of the letters. (we have many more error messages where the U is lower case)
The first occurrence is in refs.c create_symref
if (rename(lockpath, git_HEAD) < 0) {
error("Unable to create %s", git_HEAD);
goto error_unlink_return;
}The other 2 occurrences are in the lockfile.c so any place using lock files may trigger that error.
Show 10 quoted lines
> > If no other git process is currently running, this probably means a > > git process crashed in this repository earlier. Make sure no other git > > process is running and remove the file manually to continue. > > Could not apply 71a... > --- > The weird part is that the file does not exist
Not anymore when you're looking I guess, as git creates and deletes a lock file for the index quite frequently. Also when a git command shuts down roughly as expected (such as when calling a die(error message) as opposed to being terminated by the operating system), then the exit handler makes sure to remove all the lock files it held.
Show 6 quoted lines
> > Any ideas? Thanks! > -- > To unsubscribe from this list: send the line "unsubscribe git" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html