From: Eric Wong <e@80x24.org>
To: Konstantin Ryabitsev <konstantin@linuxfoundation.org>
Cc: meta@public-inbox.org
Subject: -fetch failures [was: latest make test failures on CentOS-7]
Date: Mon, 27 Sep 2021 19:33:46 +0000 [thread overview]
Message-ID: <20210927193346.GA18520@dcvr> (raw)
In-Reply-To: <20210927124056.kj5okiefvs4ztk27@meerkat.local>
Konstantin Ryabitsev <konstantin@linuxfoundation.org> wrote:
> t/v2mirror.t ................. 71/? W: /tmp/pi-v2mirror-39373-Dl1N/m/git/3.git missing remote.origin.url
> fatal: not a git repository: '/tmp/pi-v2mirror-39373-Dl1N/m/git/3.git'
> git --git-dir=/tmp/pi-v2mirror-39373-Dl1N/m/git/3.git fetch -q failed
> Bailout called. Further testing stopped: -fetch failed
> FAILED--Further testing stopped: -fetch failed
> make: *** [test_dynamic] Error 255
>
> FYI, this is git 2.31.1.
I'm not seeing this at all with 2.31.1, 2.20, 2.33...
I wonder if there's a permissions problem or some latent GIT_*
var in env...
Are you testing as root? I think that would be broken, yes.
The partial fetching would need some work to support working as
root.
> I'll be happy to help troubleshoot things as necessary.
Otherwise, dumping the config and some more info could help...
diff --git a/lib/PublicInbox/Fetch.pm b/lib/PublicInbox/Fetch.pm
index 7881b402e3f6..a5e4c43c039b 100644
--- a/lib/PublicInbox/Fetch.pm
+++ b/lib/PublicInbox/Fetch.pm
@@ -122,6 +122,10 @@ sub do_fetch { # main entry point
$epoch = $nr;
} else {
warn "W: $edir missing remote.origin.url\n";
+ my $pid = spawn([qw(git config -l)], undef,
+ { 1 => $lei->{2}, 2 => $lei->{2} });
+ waitpid($pid, 0);
+ $lei->child_error($?) if $?;
}
}
@epochs = grep { !$skip->{$_} } @epochs if $skip;
diff --git a/t/v2mirror.t b/t/v2mirror.t
index 63d17ebfebba..e3936919306b 100644
--- a/t/v2mirror.t
+++ b/t/v2mirror.t
@@ -5,6 +5,7 @@ use v5.10.1;
use PublicInbox::TestCommon;
use File::Path qw(remove_tree make_path);
use Cwd qw(abs_path);
+use Carp ();
use PublicInbox::Spawn qw(which);
require_git(2.6);
require_cmd('curl');
@@ -102,7 +103,9 @@ my @new_epochs;
my $fetch_each_epoch = sub {
my %before = map { $_ => 1 } glob("$tmpdir/m/git/*");
run_script([qw(-fetch --exit-code -q)], undef, {-C => "$tmpdir/m"}) or
- xbail '-fetch fail';
+ xbail('-fetch fail ',
+ [ xqx([which('find'), "$tmpdir/m", qw(-type f -ls) ]) ],
+ Carp::longmess());
is($?, 0, '--exit-code 0 after fetch updated');
my @after = grep { !$before{$_} } glob("$tmpdir/m/git/*");
push @new_epochs, @after;
next prev parent reply other threads:[~2021-09-27 19:33 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-27 12:40 latest make test failures on CentOS-7 Konstantin Ryabitsev
2021-09-27 18:35 ` [PATCH] t/cmd_ipc: allow extra errors and add diagnostics Eric Wong
2021-09-27 18:51 ` Konstantin Ryabitsev
2021-09-27 19:33 ` Eric Wong [this message]
2021-09-27 19:45 ` -fetch failures [was: latest make test failures on CentOS-7] Konstantin Ryabitsev
2021-09-27 21:05 ` [PATCH 0/3] fixes for odd/old/missing dependencies Eric Wong
2021-09-27 21:05 ` [PATCH 1/3] fetch: support running as root Eric Wong
2021-09-27 21:05 ` [PATCH 2/3] t/lei-index: IMAP and NNTP dependencies are optional Eric Wong
2021-09-27 21:05 ` [PATCH 3/3] lei completion: workaround old Perl bug Eric Wong
2021-09-27 21:27 ` [PATCH 0/3] fixes for odd/old/missing dependencies Konstantin Ryabitsev
2021-09-27 21:40 ` Eric Wong
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://public-inbox.org/README
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210927193346.GA18520@dcvr \
--to=e@80x24.org \
--cc=konstantin@linuxfoundation.org \
--cc=meta@public-inbox.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).