Re: bug report: mutual recursion in the git-subtree shell script
- From
- Colin Stagner <ask+git@howdoi.land>
- Date
- Mar 14, 2026, 21:36 UTC
- Message-ID
- <454235b2-139f-40bd-a4ac-fb7664962471@howdoi.land>
- In-Reply-To
- <CAN7rbOuOaHY553KX1Qcr_XWGG6DFo1yUjdYVu5mn=HYPmOj6vQ@mail.gmail.com>
Arun,
I found your git-subtree bug report from several years ago.
On 3/13/21 10:06, Arun Sharma wrote:
Show 6 quoted lines
> So I'm trying to split out a directory from postgres source code > (which has 52k commits). > > $ git subtree push --prefix=src/interfaces/libpq libpq master > /usr/lib/git-core/git-subtree: 647: Maximum function recursion depth > (1000) reached
On 3/14/21 12:31, Arun Sharma wrote:
Show 11 quoted lines
> I was using ubuntu 20.04. > > $ git --version > git version 2.25.1 > > $ bash --version > GNU bash, version 5.0.16(1)-release (x86_64-pc-linux-gnu) > > To repro, you can try to split a week old version of: > > https://github.com/postgres/postgres (subtree: src/interfaces/libpq)
Is this issue still relevant to you?
I have prepared a patch series that I hope will correct this problem. If you have the time, can you please test and review:
<https://lore.kernel.org/git/20260305-cs-subtree-split-recursion-v2-0-7266be870ba9@howdoi.land/>
Code reviews are eagerly solicited.
Colin