From 44de182766037948d62bc2a8ba924de2264dd5fc Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sat, 28 Nov 2020 07:06:50 +0000 Subject: [PATCH] searchidxshard: chomp $eidx_key from pipe We were accidentally adding "\n" to terms (which Xapian happily accepts), causing incompatibilities when enabling parallel sharding in some invocations of -extindex but not others. This is an extindex incompatibility and starting a new extindex will be required to take advantage of in-development features, so it's not urgent to start another one, either. (other incompatible things may happen before a 1.7 release) --- lib/PublicInbox/SearchIdxShard.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/PublicInbox/SearchIdxShard.pm b/lib/PublicInbox/SearchIdxShard.pm index 875a9ec9..dcfeb0be 100644 --- a/lib/PublicInbox/SearchIdxShard.pm +++ b/lib/PublicInbox/SearchIdxShard.pm @@ -83,11 +83,13 @@ sub shard_worker_loop ($$$$$) { } elsif ($line =~ s/\A\+X //) { my ($len, $docid, $oid, $eidx_key) = split(/ /, $line, 4); + chomp $eidx_key; $self->add_eidx_info($docid, $oid, $eidx_key, eml($r, $len)); } elsif ($line =~ s/\A-X //) { my ($len, $docid, $oid, $eidx_key) = split(/ /, $line, 4); + chomp $eidx_key; $self->remove_eidx_info($docid, $oid, $eidx_key, eml($r, $len)); } else { -- 2.48.1