user/dev discussion of public-inbox itself
 help / color / mirror / code / Atom feed
Search results ordered by [date|relevance]  view[summary|nested|Atom feed]
thread overview below | download mbox.gz: |
* stable 1.6.1 release? [was: [PATCH] eml: fix undefined vars on <Perl 5.28]
  @ 2020-12-26 20:35  5%     ` Eric Wong
  0 siblings, 0 replies; 2+ results
From: Eric Wong @ 2020-12-26 20:35 UTC (permalink / raw)
  To: Ali Alnubani, Konstantin Ryabitsev; +Cc: meta

Ali Alnubani <alialnu@nvidia.com> wrote:
> I no longer see the uninitialized value warnings or the test
> failure on Debian 9 with both patches applied on master. Do
> you plan on creating a new release tag soon with these fixes?

Thanks, pushed to master and I've started a stable-1.6 branch
to https://80x24.org/public-inbox.git with 29 commits
cherry-picked from master which I hope are suitable.

There's two more I'm tempted to cherry-pick, though they
introduce behavior changes:

  fe01d7b117c8b1e1 import: drop X-Status in addition to Status
  1bf653ad139bf7bb nntp+www: drop List-* and Archived-At headers

Konstantin: thoughts on 1bf653ad139bf7bb being suitable for 1.6.1?

Anyways, here's what I have so far:

fdbd73069af6eed9 eml: fix undefined vars on <Perl 5.28
e16e09b239b4d8bf t/config: test --get-urlmatch for git <2.26
933fce93167eba86 inboxidle: avoid needless syscalls on refresh
a0b470cbaf01c699 inboxidle: clue users into resolving ENOSPC from inotify
b782533a0413578d inbox: name variable for values loop iterator
4f1a683dc895a7bd public-inbox-v[12]-format.pod: make lexgrog happy
7a92c24157953dc6 manifest.js.gz: fix per-inbox /$INBOX/manifest.js.gz
78e81ae914ad24df Fix manpage section of perl module documentation
a4a1a74a2f60ec58 t/psgi_v2: ignore warnings on missing P::M::ReverseProxy
1cbb6243533fc2d4 daemon: support --daemonize without Net::Server::Daemonize
734daa9b165e248c doc: v2-format: drop repeated word
b63c27f36a44d8de over: ensure old, merged {tid} is really gone
c39ed01a3a4c6c46 wwwattach: prevent deep-linking via Referer match
0366c73f20b436d4 t/eml.t: workaround newer Email::MIME* behavior
bf14a3670da72358 nntp: attempt RFC 5536 3.1.5-conformant Path: headers
2fcf2b14a9ce3336 nntp: delimit Newsgroup: header with commas
31f9b61a318f4daf tls: epollbit: account for miscellaneous OpenSSL errors
5efbbd5e3e45ff3a scripts/dupe-finder: restore $dbh variable
59cc88bb5bc5ce3e searchidx: index lower-case List-Id value
4ccff6f9122da89c ds: add missing label for systems w/o EPOLLEXCLUSIVE
f9c3b3746445219b imap: avoid raising exception if client disconnects
e578a012532cd91f idxstack: fix comment about file_char
d94b6dd634381748 mda: match List-Id insensitively
c6ca576baf1700a8 mid: drop repeated ';' in mid_escape() regular expression
8e9d4f877730dbdf doc: post-1.6 updates, start 1.7
d6d442866106248e config: warn on multiple values for some fields
64f7ab3a571b9db0 doc: txt2pre: more manpage URLs
915e01b9cd771a84 doc: flow: include -imapd
dec02da946b6bb29 t/indexlevels-mirror: fix improperly skipped test

Thoughts?

Fwiw, I consider these two the most important and was
considering a 1.6.1 release even before the recent fixes:

  7a92c24157953dc6 manifest.js.gz: fix per-inbox /$INBOX/manifest.js.gz
  b63c27f36a44d8de over: ensure old, merged {tid} is really gone

^ permalink raw reply	[relevance 5%]

* [PATCH] t/eml.t: workaround newer Email::MIME* behavior
@ 2020-11-15  8:56  7% Eric Wong
  0 siblings, 0 replies; 2+ results
From: Eric Wong @ 2020-11-15  8:56 UTC (permalink / raw)
  To: meta

Recent (2020) versions of Email::MIME (and/or dependencies)
have different behavior than historical versions which seem
to be less DWIM and perhaps technically more correct.  We'll
retain historical behavior for now, since it doesn't seem to
cause real problems and DWIM-ness is often required to make
sense of historical mail.

Tested on a FreeBSD 11.4 VM with the following packages:

p5-Email-MIME-1.949
p5-Email-MIME-ContentType-1.024_1
p5-Email-MIME-Encodings-1.315_2
---
 t/eml.t | 32 ++++++++++++++++++++++++--------
 1 file changed, 24 insertions(+), 8 deletions(-)

diff --git a/t/eml.t b/t/eml.t
index 8d131b14..4d1c1216 100644
--- a/t/eml.t
+++ b/t/eml.t
@@ -8,6 +8,9 @@ use PublicInbox::MsgIter qw(msg_part_text);
 my @classes = qw(PublicInbox::Eml);
 SKIP: {
 	require_mods('Email::MIME', 1);
+	# TODO: Email::MIME behavior is not consistent in newer versions
+	# we need to evaluate and possibly adjust our behavior to decide
+	# between DWIM-ness with historical mail...
 	push @classes, 'PublicInbox::MIME';
 };
 use_ok $_ for @classes;
@@ -260,6 +263,9 @@ EOF
 }
 
 for my $cls (@classes) {
+SKIP: {
+	skip 'newer Email::MIME behavior inconsistent', 1 if
+		$cls eq 'PublicInbox::MIME';
 	my $s = <<EOF; # buggy git-send-email versions, again?
 Content-Type: text/plain; =?ISO-8859-1?Q?=20charset=3D=1BOF?=
 Content-Transfer-Encoding: 8bit
@@ -269,7 +275,8 @@ Object-Id: ab0440d8cd6d843bee9a27709a459ce3b2bdb94d (lore/kvm)
 EOF
 	my $eml = $cls->new(\$s);
 	my ($str, $err) = msg_part_text($eml, $eml->content_type);
-	is($str, "\x{100}\n", "got wide character by assuming utf-8");
+	is($str, "\x{100}\n", "got wide character by assuming utf-8 ($cls)");
+} # SKIP
 }
 
 if ('we differ from Email::MIME with final "\n" on missing epilogue') {
@@ -383,8 +390,12 @@ SKIP: {
 		$msg->parts_set([$old[-1]]);
 		is(scalar $msg->subparts, 1, 'only last remains');
 	}
-	is($eml->as_string, $mime->as_string,
-		'as_string matches after parts_set');
+
+	# some versions of Email::MIME or Email::MIME::* will drop
+	# unnecessary ", while PublicInbox::Eml will preserve the original
+	my $exp = $mime->as_string;
+	$exp =~ s/; boundary=b\b/; boundary="b"/;
+	is($eml->as_string, $exp, 'as_string matches after parts_set');
 }
 
 for my $cls (@classes) {
@@ -395,7 +406,8 @@ Content-Disposition: attachment; filename="=?utf-8?q?vtpm-makefile.patch?="
 EOF
 	is($cls->new($s)->filename, 'vtpm-makefile.patch', 'filename decoded');
 	$s =~ s/^Content-Disposition:.*$//sm;
-	is($cls->new($s)->filename, 'vtpm-fakefile.patch', 'filename fallback');
+	is($cls->new($s)->filename, 'vtpm-fakefile.patch',
+		"filename fallback ($cls)") if $cls ne 'PublicInbox::MIME';
 	is($cls->new($s)->content_type,
 		'text/x-patch; name="vtpm-fakefile.patch"',
 		'matches Email::MIME output, "correct" or not');
@@ -413,10 +425,14 @@ Content-Type: text/x-patch; name="=?utf-8?q?vtpm-fakefile.patch?="
 b
 --b--
 EOF
-	my @tmp;
-	$cls->new($s)->each_part(sub { push @tmp, $_[0]->[0]->filename });
-	is_deeply(['vtpm-makefile.patch', 'vtpm-fakefile.patch'], \@tmp,
-		'got filename for both attachments');
+	SKIP: {
+		skip 'newer Email::MIME is inconsistent here', 1
+			if $cls eq 'PublicInbox::MIME';
+		my @x;
+		$cls->new($s)->each_part(sub { push @x, $_[0]->[0]->filename });
+		is_deeply(['vtpm-makefile.patch', 'vtpm-fakefile.patch'], \@x,
+			"got filename for both attachments ($cls)");
+	}
 }
 
 done_testing;

^ permalink raw reply related	[relevance 7%]

Results 1-2 of 2 | reverse | options above
-- pct% links below jump to the message on this page, permalinks otherwise --
2020-11-15  8:56  7% [PATCH] t/eml.t: workaround newer Email::MIME* behavior Eric Wong
2020-12-26 11:27     [Debian 9][Perl 5.24] uninitialized value errors in Encode/MIME/Header.pm Ali Alnubani
2020-12-26 12:25     ` [PATCH] eml: fix undefined vars on <Perl 5.28 Eric Wong
2020-12-26 14:10       ` Ali Alnubani
2020-12-26 20:35  5%     ` stable 1.6.1 release? [was: [PATCH] eml: fix undefined vars on <Perl 5.28] Eric Wong

Code repositories for project(s) associated with this public inbox

	https://80x24.org/public-inbox.git

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).