Re: fatal: unable to read <hash>

From: Warner Losh <imp_at_bsdimp.com>
Date: Wed, 26 Jul 2023 01:38:53 UTC
Have you tried cloning the repo?

On Tue, Jul 25, 2023, 6:22 PM Bjoern A. Zeeb <bzeeb-lists@lists.zabbadoz.net>
wrote:

> Hi,
>
> on one of my trees I am getting:
>
> --- 8< 8< 8< -----------------------------------------------------------
> % git fetch freebsd
> Auto packing the repository in background for optimum performance.
> See "git help gc" for manual housekeeping.
> warning: The last gc run reported the following. Please correct the root
> cause
> and remove .git/gc.log
> Automatic cleanup will not be performed until the file is removed.
>
> fatal: unable to read b9cdc058e6eb1b3d8b5e29ad9b911d3da98f65a7
> fatal: failed to run repack
> --- 8< 8< 8< -----------------------------------------------------------
>
> I am not concerned about the background gc but the fatal error about the
> hash displayed.
>
> I have no clue how to solve this, nor do I know what object that hash
> is/was.
>
> Does anyone know how to "repair" this wihtout having to blow away the
> local copy with all its development branches (which would be rather
> painful)?
>
> /bz
>
> --
> Bjoern A. Zeeb                                                     r15:7
>
>