Re: git doesn't finds the parent of a commit
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Apr 27, 2008, 20:18 UTC
- Message-ID
- <7vtzhnf3w5.fsf@gitster.siamese.dyndns.org>
- In-Reply-To
- <20080427173731.GA9523@cuci.nl>
"Stephen R. van den Berg" <srb@cuci.nl> writes:
Show 13 quoted lines
> J?rg Sommer wrote: >>% git rev-parse b63e99500137c913bd801a2f22b6cf88c63b95c5~1 >>b63e99500137c913bd801a2f22b6cf88c63b95c5~1 >>fatal: ambiguous argument 'b63e99500137c913bd801a2f22b6cf88c63b95c5~1': unknown revision or path not in the working tree. >>Use '--' to separate paths from revisions > >>Can someone tell me what I'm doing wrong? > > I've had similar symptoms when I had circular references in the > repository. They're not reported by any of the existing checks, I've > submitted a patch (resent it just now) which causes git to check for > (and report) circular references when using --topo-order on e.g. > git-rev-list.
Assuming that we never have SHA-1 hash collisions, the graft mechansim is practically the only way to get yourself into the circular reference situation.
Perhaps we should check this circularity when we install grafts instead of special casing the topo-order codepath? How expensive would that alternative approach be?