Debugging a bizarre problem: What can influence 'git fetch'?

3 messages, 2 authors, 2016-06-15 · open the first message on its own page

Debugging a bizarre problem: What can influence 'git fetch'?

From: <hidden>
Date: 2016-06-15 22:56:17

Hello.

I'm working on a small project that talks to external git and fossil
repositories. I've run into a bizarre "this cannot happen" problem and
am completely mystified as to what's causing it.

Essentially, the problem is that a particular git command, run as part
of the unit tests for the project, fails reliably when executed from
the project's build system but works correctly when run directly from the
command line or when the same unit tests are executed from the IDE).

The unit test executes the following commands (where e5KbuUvD4Ps is a
random string to ensure that each invocation of the test starts from a
blank canvas):

/usr/bin/git clone --mirror --bare http://git.io7m.com/io7m-jaux.git /tmp/test-e5KbuUvD4Ps/io7m-jaux.git
/usr/bin/git --git-dir=/tmp/test-e5KbuUvD4Ps/io7m-jaux.git fetch -v

The 'git fetch' command raises the following error:

error: Unable to find f981a2bb02c38f20c1e3a5a0fc37c2b4ef5b92ea under http://git.io7m.com/io7m-jaux.git
Cannot obtain needed object f981a2bb02c38f20c1e3a5a0fc37c2b4ef5b92ea
error: Fetch failed.

The f981a2bb02c38f20c1e3a5a0fc37c2b4ef5b92ea is the HEAD commit of the master
branch in the above repos.

I can execute the fetch command from the command line (on the same clones created
by any past invocations of the unit test) and it works correctly. I can run the unit
test from the IDE and it works correctly.

In desperation, I've replaced the git binary with a shell script that logs
the current environment and command line arguments to a file before executing
the real git binary and in all cases, they're completely identical.

I'm out of ideas. What bizarre invisible environment pollution could possibly
be influencing 'git fetch' in this manner? Is there some way to get 'git fetch'
to be more verbose?

M

Re: Debugging a bizarre problem: What can influence 'git fetch'?

From: Tay Ray Chuan <hidden>
Date: 2016-06-15 22:56:17

On Fri, Mar 1, 2013 at 10:39 PM,  [off-list ref] wrote:
Is there some way to get 'git fetch'
to be more verbose?
It seems that the remote is running the 'dumb' http protocol, you
might want to try setting the GIT_CURL_VERBOSE environment variable
for more verbosity.

Have you tried running git-update-server-info on the remote side?
Perhaps a push/fetch led to packs being created so the f981a2b object
isn't available as a loose object but in a pack but the remote still
indicates otherwise.

--
Cheers,
Ray Chuan

Re: Debugging a bizarre problem: What can influence 'git fetch'?

From: <hidden>
Date: 2016-06-15 22:56:17

On Sat, 2 Mar 2013 18:32:17 +0800
Tay Ray Chuan [off-list ref] wrote:
It seems that the remote is running the 'dumb' http protocol, you
might want to try setting the GIT_CURL_VERBOSE environment variable
for more verbosity.

Have you tried running git-update-server-info on the remote side?
Perhaps a push/fetch led to packs being created so the f981a2b object
isn't available as a loose object but in a pack but the remote still
indicates otherwise.
Hi.

Yes, git-update-server-info has been used on the remote but to no avail.

I'll try GIT_CURL_VERBOSE. Thanks!

M
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help