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

Re: pull.rebase config option broken in 2.33.1

From
Elijah Newren <newren@gmail.com>
Date
Nov 27, 2021, 05:27 UTC
Message-ID
<CABPp-BFdtEB5chYz9tPxJ=M-4U408P7apiROD1-538sb5+aiDg@mail.gmail.com>
In-Reply-To
<YYFEE/2g3SiM04zx@hades.panopticon>
Hi Dmitry,
On Tue, Nov 2, 2021 at 7:09 AM Dmitry Marakasov <amdmi3@amdmi3.ru> wrote:
Show 11 quoted lines
>
> Hi!
>
> After update from 2.33.0 to 2.33.1 the pull.rebase = true option
> no longer works: `git pull` no longer tries to rebase (however manual
> `git pull --rebase` works fine):
>
> % git config pull.rebase
> true
> % git pull
> fatal: Not possible to fast-forward, aborting.

Was pull.ff also set? As per https://lore.kernel.org/git/xmqqzgr3pso7.fsf@gitster.g/, --ff-only overrides --rebase if both are given on the command line, and by the same token, pull.ff=only will override a pull.rebase=true if both are set.

Yes, I know it's weird that we have two separate potentially contradictory settings. A single pull.mode would be better, but the backward compatibility story to migrate is a long story. Prior to v2.33.1/v2.34.0, we had a bunch of untested and mishandled interactions.

> % git pull --rebase
> Successfully rebased and updated refs/heads/local-fixes.

Right, the command-line options take precedence over config, so if you add pull.ff=only, the --rebase overrides.

> % git pull
> fatal: Not possible to fast-forward, aborting.

This was the bug fixed in v2.34.1; see ea1954af77 ("pull: should be noop when already-up-to-date", 2021-11-17)

Show 10 quoted lines
> % grep -C1 rebase .git/config
> [pull]
>         rebase = true
> [rebase]
>         autostash = true
>
> After downgrade to 2.33.0:
>
> % git pull
> Current branch local-fixes is up to date.
Previous: Elijah Newren
Message 11 of 11 in “pull.rebase config option broken in 2.33.1”
  1. Dmitry MarakasovNov 2, 2021
  2. Jeff KingNov 2, 2021
  3. Dmitry MarakasovNov 26, 2021
  4. Jeff KingNov 26, 2021
  5. Jeff KingNov 26, 2021
  6. Elijah NewrenNov 26, 2021
  7. Jeff KingNov 27, 2021
  8. Elijah NewrenNov 27, 2021
  9. Dmitry MarakasovDec 2, 2021
  10. Elijah NewrenDec 2, 2021
  11. Elijah NewrenNov 27, 2021

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.