Bug#943724: lintian: internal error in Lintian::files::empty_package::_set_is_dummy
Hi everyone, On Wed, Oct 30, 2019 at 2:55 PM Thorsten Glaser wrote: > > indeed, ... [my] script uses -o APT::Install-Recommends=true Starting with the next release, your build experience will match ours. Lintian now depends on libclass-xsaccessor-perl. Thank you for your goodwill. Kind regards, Felix Lechner
Bug#943724: lintian: internal error in Lintian::files::empty_package::_set_is_dummy
Hi, Felix Lechner: > I also committed another fix, which I found more appropriate after > discussing the issue with Moo's author. Great! I almost did exactly that (it feels better indeed) before I went with a less invasive approach :) Cheers, -- intrigeri
Bug#943724: lintian: internal error in Lintian::files::empty_package::_set_is_dummy
Hi Felix, >> Yes, it’s a direct Depends of lintian or one of its direct Depends. > >FTR, I only see it as recommended by libmoo-perl (which is required). indeed, I misspoke as the script uses -o APT::Install-Recommends=true to override the buildd default of false for installing lintian after the build ONLY. >> This fixes the issue for me when I hand-apply it in the chroot to >> …/usr/share/perl5/Lintian/Collect/Binary.pm > >Thanks for testing the proposed fix. Please accept our apologies for >the inconvenience. No problem, and thanks for the quick fix! bye, //mirabilos -- 15:41⎜ Somebody write a testsuite for helloworld :-)
Bug#943724: lintian: internal error in Lintian::files::empty_package::_set_is_dummy
Hi Thorsten, On Wed, Oct 30, 2019 at 2:07 PM Thorsten Glaser wrote: > > Yes, it’s a direct Depends of lintian or one of its direct Depends. FTR, I only see it as recommended by libmoo-perl (which is required). Until now, I ran Lintian without it. > This fixes the issue for me when I hand-apply it in the chroot to > …/usr/share/perl5/Lintian/Collect/Binary.pm Thanks for testing the proposed fix. Please accept our apologies for the inconvenience. Kind regards, Felix Lechner
Bug#943724: lintian: internal error in Lintian::files::empty_package::_set_is_dummy
Felix Lechner dixit: >Also, please let us know if your chroot or cowbuilder environment had >libclass-xsaccessor-perl installed. (Note the XS in the name; there Yes, it’s a direct Depends of lintian or one of its direct Depends. >I also committed another fix, which I found more appropriate after >discussing the issue with Moo's author. The commit message has more >details and is replicated below. > >are other similar packages in the archive.) > > > https://salsa.debian.org/lintian/lintian/commit/b951f0d4d83fa76286d1f4bd5836cf256038f31c This fixes the issue for me when I hand-apply it in the chroot to …/usr/share/perl5/Lintian/Collect/Binary.pm Thanks, //mirabilos -- FWIW, I'm quite impressed with mksh interactively. I thought it was much *much* more bare bones. But it turns out it beats the living hell out of ksh93 in that respect. I'd even consider it for my daily use if I hadn't wasted half my life on my zsh setup. :-) -- Frank Terbeck in #!/bin/mksh
Bug#943724: lintian: internal error in Lintian::files::empty_package::_set_is_dummy
Hi, I also committed another fix, which I found more appropriate after discussing the issue with Moo's author. The commit message has more details and is replicated below. Also, please let us know if your chroot or cowbuilder environment had libclass-xsaccessor-perl installed. (Note the XS in the name; there are other similar packages in the archive.) https://salsa.debian.org/lintian/lintian/commit/b951f0d4d83fa76286d1f4bd5836cf256038f31c Kind regards, Felix Lechner * * * Clarify boolean return value in Collect::Binary->is_pkg_class. (Closes: #943724) According to Moo's author haarg, Moo optionally looks for Class::XSAccessor, which in turn requires a argument to be passed to a writer. The undef return value is interpreted as providing the wrong number of arguments. Moo's behavior is documented here: https://metacpan.org/pod/Moo#MOO-AND-CLASS::XSACCESSOR The availability of Class::XSAccessor determines who sees the bug. The module was probably installed automatically in the chroot and cowbuilder environments that gave gise to the bug report. This can be tested: The error also occurs in logrotate/3.15.1-1 in Debian stable when libclass-xsaccessor-perl is installed. Thank you to intrigeri for shedding light on the issue and for putting forward this merge request: https://salsa.debian.org/lintian/lintian/merge_requests/266 Contrary to the fix proposed there, which forces the value returned to a scalar in the consuming package, this commit causes ->is_pkg_class to return 0 instead of undef (which evaluates to an empty list in list context). The undef return value is interpreted as providing the wrong number of arguments in the mechanics behind the accessor _set_is_dummy. Thanks to ilmari on #perl-help for identifing the proper fix and for explaining the issue. As an aside, installing libclass-xsaccessor-perl has another effect in Lintian. It causes the style tests for POD coverage to fail: ===( 15295;22 33/? 34/? 159/? 97/? 67/? 4/19 0/? 0/? ... )===# Failed test 'Lintian::Lab is covered' # at t/scripts/pod-coverage.t line 52. # Coverage for Lintian::Lab is 50.0%, with 2 naked subroutines: # basedir # keep # Failed test 'Lintian::Processable::Group is covered' # at t/scripts/pod-coverage.t line 52. # Coverage for Lintian::Processable::Group is 66.7%, with 7 naked subroutines: # binary # buildinfo # changes # lab # name # source # udeb # Failed test 'Lintian::Processable::Pool is covered' # at t/scripts/pod-coverage.t line 52. # Coverage for Lintian::Processable::Pool is 66.7%, with 3 naked subroutines: # groups # lab # unpacker # Looks like you failed 3 tests of 19. t/scripts/pod-coverage.t ... Dubious, test returned 3 (wstat 768, 0x300) Failed 3/19 subtests The error that gave rise to the original bug report was: Usage: Lintian::files::empty_package::_set_is_dummy(self, newvalue) at /usr/share/lintian/checks/files/empty-package.pm line 42. internal error: cannot run files check on package binary:logrotate/3.15.1-1/amd64 warning: skipping check of binary:logrotate/3.15.1-1/amd64 Clarifies the boolean return type to avoid problems with Moo attribute accessors.
Bug#943724: lintian: internal error in Lintian::files::empty_package::_set_is_dummy
Control: tag -1 + patch Hi, I believe I partly understood the bug. I did not dive into why it does not happen in all cases; but I suspect this has to do with the recent librole-tiny-perl updates. Regardless, my understanding is that the affected Lintian code was not entirely correct, and used to work merely by luck, while my proposed fix makes it more correct and robust: https://salsa.debian.org/lintian/lintian/merge_requests/266 Cheers!
Bug#943724: lintian: internal error in Lintian::files::empty_package::_set_is_dummy
Package: lintian Version: 2.31.0 Followup-For: Bug #943724 I’ve just hit this as well, but only in cowbuilder; I cannot seem to reproduce it outside of the chroot. Perhaps a missing dependency (or (recursive) Recommends) that’s installed outside but not inside? N: Processing binary package fonts-campania (version 2.009-1, arch all) ... […] Usage: Lintian::files::empty_package::_set_is_dummy(self, newvalue) at /usr/share/lintian/checks/files/empty-package.pm line 42. internal error: cannot run files check on package binary:fonts-campania/2.009-1/all warning: skipping check of binary:fonts-campania/2.009-1/all N: Finished processing group campania/2.009-1 Both the host system and the cowbuilder chroot are freshly dist-upgraded sid. -- System Information: Debian Release: bullseye/sid APT prefers buildd-unstable APT policy: (500, 'buildd-unstable'), (500, 'unstable'), (1, 'experimental') Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 5.3.0-1-amd64 (SMP w/2 CPU cores) Kernel taint flags: TAINT_CRAP Locale: LANG=C, LC_CTYPE=C.UTF-8 (charmap=UTF-8), LANGUAGE=C (charmap=UTF-8) Shell: /bin/sh linked to /bin/lksh Init: sysvinit (via /sbin/init) Versions of packages lintian depends on: ii binutils 2.33.1-2 ii bzip21.0.8-2 ii diffstat 1.62-1+b1 ii dpkg 1.19.7 ii dpkg-dev 1.19.7 ii file 1:5.37-6 ii gettext 0.19.8.1-9 ii gpg 2.2.17-3 ii intltool-debian 0.35.0+20060710.5 ii libapt-pkg-perl 0.1.36+b2 ii libarchive-zip-perl 1.67-1 ii libberkeleydb-perl 0.62-1+b1 ii libcapture-tiny-perl 0.48-1 ii libcgi-pm-perl 4.44-1 ii libclass-accessor-perl 0.51-1 ii libclone-perl0.41-1+b2 ii libdpkg-perl 1.19.7 ii libemail-valid-perl 1.202-1 ii libfile-basedir-perl 0.08-1 ii libfile-find-rule-perl 0.34-1 ii libio-async-loop-epoll-perl 0.20-1 ii libio-async-perl 0.74-1 ii libipc-run-perl 20180523.0-1 ii liblist-compare-perl 0.53-1 ii liblist-moreutils-perl 0.416-1+b5 ii libmldbm-perl2.05-2 ii libmoo-perl 2.003004-2 ii libpath-tiny-perl0.108-1 ii libtext-levenshtein-perl 0.13-1 ii libtimedate-perl 2.3000-2 ii libtry-tiny-perl 0.30-1 ii libtype-tiny-perl1.004004-1 ii liburi-perl 1.76-1 ii libxml-simple-perl 2.25-1 ii libyaml-libyaml-perl 0.80+repack-2+b1 ii man-db 2.9.0-1 ii patchutils 0.3.4-2+b1 ii perl [libdigest-sha-perl]5.30.0-9 ii t1utils 1.41-3 ii xz-utils 5.2.4-1+b1 Versions of packages lintian recommends: pn libperlio-gzip-perl Versions of packages lintian suggests: ii binutils-multiarch 2.33.1-2 ii libhtml-parser-perl3.72-3+b4 pn libtext-template-perl -- no debconf information
Bug#943724: lintian: internal error in Lintian::files::empty_package::_set_is_dummy
Package: lintian Version: 2.30.0 While working on the logrotate package, lintian errored out: $ lintian ../build-area/logrotate_3.15.1-2_amd64.changes W: logrotate source: orig-tarball-missing-upstream-signature logrotate_3.15.1.orig.tar.xz W: logrotate source: spelling-error-in-patch-description debian/patches/0010-testsuite-remove-explicit-group-and-other-write-perm.patch genrated generated Usage: Lintian::files::empty_package::_set_is_dummy(self, newvalue) at /usr/share/lintian/checks/files/empty-package.pm line 42. internal error: cannot run files check on package binary:logrotate-dbgsym/3.15.1-2/amd64 warning: skipping check of binary:logrotate-dbgsym/3.15.1-2/amd64 Usage: Lintian::files::empty_package::_set_is_dummy(self, newvalue) at /usr/share/lintian/checks/files/empty-package.pm line 42. internal error: cannot run files check on package binary:logrotate/3.15.1-2/amd64 warning: skipping check of binary:logrotate/3.15.1-2/amd64