git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: What's cooking in git.git (Oct 2018, #04; Fri, 19)

From
Alban Gruin <alban.gruin@gmail.com>
Date
Oct 20, 2018, 14:31 UTC
Message-ID
<5f0fb76f-0774-3545-38fc-b86137f747fa@gmail.com>
In-Reply-To
<6e4fdcdd-6c50-a07e-74b7-1fcd15c33444@gmail.com>
Le 19/10/2018 à 20:05, Alban Gruin a écrit :
Show 17 quoted lines
> Le 19/10/2018 à 14:46, SZEDER Gábor a écrit :
>> On Fri, Oct 19, 2018 at 03:02:22PM +0900, Junio C Hamano wrote:
>>> Two large set of topics on "rebase in C" and "rebase -i in C" are
>>> now in 'next'.
>>
>> I see occasional failures in 't5520-pull.sh':
>>
>> […]
>>
>> When running t5520 in a loop, it tends to fail between 10-40
>> iterations, even when the machine is not under heavy load.
>>
>> It appears that these failures started with commit 5541bd5b8f (rebase:
>> default to using the builtin rebase, 2018-08-08), i.e. tip of
>> 'pk/rebase-in-c-6-final', but it's a "flip the big switch" commit, so
>> not very useful...
>>

The bug can be bisected by prepending the command chain of 5520.25 with `git config --bool rebase.usebuiltin true &&`. Commit 7debdaa4ad (“builtin rebase: support `--autostash` option”) is the culprit, but some commits that cause this test to fail with a different error (ie. “TODO”…) must be marked as good.

The error comes from the call to `git stash apply $stash_id' in builtin/rebase.c:261. When $stash_id only contains decimals and no letters, git-stash tries to apply stash@{$stash_id}[0][1]. Thas was not a real problem with the shell script, because it did not abbreviate the object id of the stashed commit, so it was very unlikely that the oid would contain only digits. builtin/rebase.c shortens the oid[2], making this problem more likely to occur.

We could add a switch to git-stash to tell it that the parameter is an oid, not anything else.

[0] https://github.com/git/git/blob/master/git-stash.sh#L514-L520 [1] https://github.com/git/git/blob/pu/builtin/stash.c#L167-L168 [2] https://github.com/git/git/blob/next/builtin/rebase.c#L1373

Cheers, Alban

Previous: Alban GruinNext: Junio C Hamano
Message 4 of 8 in “What's cooking in git.git (Oct 2018, #04; Fri, 19)”
  1. Junio C HamanoOct 19, 2018
  2. SZEDER GáborOct 19, 2018
  3. Alban GruinOct 19, 2018
  4. Alban GruinOct 20, 2018
  5. Junio C HamanoOct 20, 2018
  6. Johannes SchindelinOct 22, 2018
  7. Derrick StoleeOct 19, 2018
  8. Johannes SixtOct 19, 2018

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.