#1003353 lintian: Cannot use brackets in suppression rules?

Package:
lintian
Source:
lintian
Submitter:
Samuel Thibault
Date:
2022-06-20 14:39:16 UTC
Severity:
serious
Tags:
#1003353#5
Date:
2022-01-08 20:02:35 UTC
From:
To:
Hello,

Seeing that qa.debian.org is using version 2.114.123 of lintian, I
upgraded my lintian from its git tree, only to find that it seems I
cannot update my suppression rule according to the new output:

W: libbrlapi-dev: bad-whatis-entry [usr/share/man/man3/brlapi_authClientPacket_t.3.gz]
W: libbrlapi-dev: mismatched-override bad-whatis-entry [usr/share/man/man3/brlapi_*] [usr/share/lintian/overrides/libbrlapi-dev:2]

I did have updated this rule to include brackets:

bad-whatis-entry [usr/share/man/man3/brlapi_*]

but that doesn't seem to be working. I also tried to use escaping (which
had fixed things for the ${} case), but to no avail:

bad-whatis-entry \[usr/share/man/man3/brlapi_*\]

Lintian has recently been annoying enough that I'm unsure I'd continue
monitoring its output any more.

Samuel

#1003353#26
Date:
2022-06-13 03:15:19 UTC
From:
To:
unmerge 1003272
unmerge 1003353
unmerge 1007002
tag 1003272 + pending
notfound 1003272 2.114.123
retitle 1003353 lintian: Override processing defective for square brackets and curly brackets
notfound 1003353 2.114.0
severity 1007002 important
notfound 1007002 2.114.123
tag 1007002 + wontfix
kthxbye

Hi again,

I disagree that #1003272, #1003353 and #1007002 are the same bug. The
former two are similar, but not identical and the latter was only the
reason why the second one is showing up more often. Hence unmerging
all three.

Axel Beckert wrote in #1003272:

And it actually fixed Tobias' issue. I can reproduce Tobias' issue
with 2.114.0, but no more the current git HEAD (which is approximately
2.114.211, git commit 1c7bb81662e5e23a64fc272a008ddfc75c855537 or so).

This is actually #1003353 which claims that processing of parentheses
is broken, too, but actually only seems to be about brackets.

This issue is still present in the current git HEAD. Will handle that
one separately later.

And #1007002 is only (!) about design decision to change nearly all
tag formats involving file paths and line numbers. It has nothing to
do with the other two real bugs and I have no idea why they have been
merged.

While I was (and still am) annoyed by these changes, I do value the
goal behind it. I currently suspect that we're mostly through this
migration and I do hope that no such mass-changes will ever be needed
again. Especially since — as I wrote — the following will likely never
happen without Felix working on Lintian:

Since at least I will not revert such huge changes, I'll tag #1007002
as "wontfix" for now and downgrade it to its original severity.

We can continue working on that bug report if we find someone who
either will work on reverting all the related work (although I think,
it's both, too late and also probably way too much work given all the
other recent changes) or, probably much better, provide either a
migration script or some code which also accepts the old override
formats. In that case, I'd remove the "wontfix" again. (Sorry, Simon,
I generally agree with #1007002, but we currently have way more severe
issues with Lintian than #1007002. Hence I also didn't remove the
confirmed tag.)

		Regards, Axel

#1003353#45
Date:
2022-06-19 14:27:38 UTC
From:
To:
Hi Andreas,

Andreas Beckmann wrote:

please explain what makes you think that this issue is present in
lintian 2.114.0 as currently in Debian Unstable.

The submitter clearly said he ran into it when he bumped his lintian
copy to git HEAD.

And as far as I can see that problem is only present if Lintian uses
Text::Glob for evaluating wildcards in overrides and that got
introduced 32 commits _AFTER_ the 2.114.0 release:

  commit 139009d5a54225ebff4509ec37b979cb898c17fe
  Author: Felix Lechner <felix.lechner@lease-up.com>
  Date:   Wed Dec 1 21:46:24 2021 -0800

    Use Text::Glob to match hint contexts with override patterns.

    Replaces a trusted homegrown routine.

    Gbp-Dch: ignore

(No idea why this was marked "Gbp-Dch: Ignore" as it has quite some
impact, also on dependencies and build-dependencies. *grrr*)

And:

  ~/lintian/lintian → git describe 139009d5a54225ebff4509ec37b979cb898c17fe
  2.114.0-32-g139009d5a
  ^^^^^^^^^^

Which is the reason why I marked this bug report as NOT being found in
2.114.0 a few days ago. (And now again.)

So please refrain from marking this specific bug report as found in
2.114.0 again unless you have a really good reason to do so. Thanks in
advance!

		Regards, Axel

#1003353#50
Date:
2022-06-19 23:37:46 UTC
From:
To:
Hello,

Bug #1003353 in lintian reported by you has been fixed in the
Git repository and is awaiting an upload. You can see the commit
message below and you can check the diff of the fix at:

https://salsa.debian.org/lintian/lintian/-/commit/f258329316d2882f9acee2eb32f0f9f4a24bd197
------------------------------------------------------------------------
Replace unfitting Text::Glob with more flexible Regexp::Wildcards

Write a match_glob() function which emulates Text::Glob's match_glob()
preconfigured for Lintian's needs, put it into Lintian::Utils and
allow to export it from there.

The mentioned preconfiguration for just using the "Jokers" set of
Regexp::Wildcards fixes the issues with brackets in overrides which
Lintian had since the introduction of Text::Glob in commit
139009d5a54225ebff4509ec37b979cb898c17fe.

Closes: #1003353

This also allows us to remove one item from the exception list for
Perl::Critic's Variables::ProhibitPackageVars policy as we no more
need to configure Text::Glob every time (!) when we call match_glob().

Also update the dependencies accordingly.
------------------------------------------------------------------------

(this message was generated automatically)
-- 
Greetings

https://bugs.debian.org/1003353

#1003353#57
Date:
2022-06-20 00:03:59 UTC
From:
To:
Hi Samuel,

Samuel Thibault wrote:

Cause was the switch of was this commit from 6 months ago:

commit 139009d5a54225ebff4509ec37b979cb898c17fe
Author: Felix Lechner <felix.lechner@lease-up.com>
Date:   Wed Dec 1 21:46:24 2021 -0800

    Use Text::Glob to match hint contexts with override patterns.

    Replaces a trusted homegrown routine.

    Gbp-Dch: ignore

I neither understand why you would replace something "trusted" and
additionally not even plan to mention such a invasive commit in the
changelog.

And because Text::Glob also interprets brackets (and curly braces) and
you can't disable that, such issues were just waiting to happen.

And together with the brackets using "pointed hints" concept
introduced at around the same time, this caused really havoc.

*nod* JFYI, in case you didn't notice it (it happend months after your
bug report), but there was an "O: lintian" WNPP bug report in the
meantime: https://bugs.debian.org/1012289

So I'm now trying to clean up the shattered remains which the previous
(recent) Lintian maintainer(s) left behind.

For now I'm trying to get a current lintian version back into Testing,
i.e. I'm concentrating on RC and important bugs as well as bugs which
are annoying and easy to fix, e.g. those with a patch or MR.

At least the lintian internal test suite is no more failing. Although
it likely has some false negatives as it seems that the test suite is
no more able to run more than one check in one test. And running a
test against multiple checks at the same time seems critical to write
tests for issues like this one. Meh.

Anyway, my feature branch for this bug report is
https://salsa.debian.org/lintian/lintian/-/commits/brackets-in-overrides-rc-bug-1003353
but I will likely force-push that branch some more times, so the
commit message in
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1003353#50 might
become stale soon while I refine the commit before that (which
contains a test for this bug), but the patch will likely stay valid.
You also might get further such mails when I force-push new histories
in that feature branch. I hope you don't mind, but I wanted to publish
what I already have.

		Regards, Axel

#1003353#62
Date:
2022-06-20 01:51:19 UTC
From:
To:
Hello,

Bug #1003353 in lintian reported by you has been fixed in the
Git repository and is awaiting an upload. You can see the commit
message below and you can check the diff of the fix at:

https://salsa.debian.org/lintian/lintian/-/commit/91b36bc14ea6d011b4107bb21b2a80c18aa0586f
------------------------------------------------------------------------
Replace unfitting Text::Glob with more flexible Regexp::Wildcards

Write a match_glob() function which emulates Text::Glob's match_glob()
preconfigured for Lintian's needs, put it into Lintian::Utils and
allow to export it from there.

The mentioned preconfiguration for just using the "Jokers" set of
Regexp::Wildcards fixes the issues with brackets in overrides which
Lintian had since the introduction of Text::Glob in commit
139009d5a54225ebff4509ec37b979cb898c17fe.

Closes: #1003353

This also allows us to remove one item from the exception list for
Perl::Critic's Variables::ProhibitPackageVars policy as we no more
need to configure Text::Glob every time (!) when we call match_glob().

Also update the dependencies accordingly.
------------------------------------------------------------------------

(this message was generated automatically)
-- 
Greetings

https://bugs.debian.org/1003353

#1003353#67
Date:
2022-06-20 06:59:31 UTC
From:
To:
Control: tag -1 sid

The BTS does not understand made up versions (i.e. versions not in the
archive), so this bug shows up e.g. as a RC bug in stable.
So limiting this bug with an incorrect version to sid+ was the smaller
lie ...

Andreas

#1003353#74
Date:
2022-06-20 10:23:25 UTC
From:
To:
Hi Andreas,

Andreas Beckmann wrote:

Yes, I'm aware of that.

Ah! I wasn't aware of that. Thanks for the explanation.

I mostly consider these non-official versions to be informational for
humans. Didn't expect such an impact.

Well, I prefer the tagging much more than the wrong version, even if
it's the same lie. That way there's more information in there for us
humans.

And yes, that weird versioning the previous maintainers started and
even claim that it is semantic versioning despite it's not semantic
versioning (https://semver.org/) at all, will likely be killed, once I
understand how lintian.d.o works (or not) nowadays.

		Regards, Axel

#1003353#77
Date:
2022-06-20 14:20:39 UTC
From:
To:
Hello,

Bug #1003353 in lintian reported by you has been fixed in the
Git repository and is awaiting an upload. You can see the commit
message below and you can check the diff of the fix at:

https://salsa.debian.org/lintian/lintian/-/commit/91b36bc14ea6d011b4107bb21b2a80c18aa0586f
------------------------------------------------------------------------
Replace unfitting Text::Glob with more flexible Regexp::Wildcards

Write a match_glob() function which emulates Text::Glob's match_glob()
preconfigured for Lintian's needs, put it into Lintian::Utils and
allow to export it from there.

The mentioned preconfiguration for just using the "Jokers" set of
Regexp::Wildcards fixes the issues with brackets in overrides which
Lintian had since the introduction of Text::Glob in commit
139009d5a54225ebff4509ec37b979cb898c17fe.

Closes: #1003353

This also allows us to remove one item from the exception list for
Perl::Critic's Variables::ProhibitPackageVars policy as we no more
need to configure Text::Glob every time (!) when we call match_glob().

Also update the dependencies accordingly.
------------------------------------------------------------------------

(this message was generated automatically)
-- 
Greetings

https://bugs.debian.org/1003353

#1003353#82
Date:
2022-06-20 14:34:13 UTC
From:
To:
We believe that the bug you reported is fixed in the latest version of
lintian, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 1003353@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Axel Beckert <abe@debian.org> (supplier of updated lintian package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)
Format: 1.8
Date: Mon, 20 Jun 2022 13:23:02 +0200
Source: lintian
Architecture: source
Version: 2.115.0
Distribution: unstable
Urgency: medium
Maintainer: Debian Lintian Maintainers <lintian-maint@debian.org>
Changed-By: Axel Beckert <abe@debian.org>
Closes: 657390 932634 941656 963099 989381 995286 996740 999768 999810 1000234 1000977 1001655 1002828 1003131 1003272 1003353 1003456 1003668 1003817 1003913 1003941 1004231 1004239 1004240 1004660 1005046 1005184 1005762 1006390 1006859 1007140 1007257 1012090
Changes:
 lintian (2.115.0) unstable; urgency=medium
 .
   The Lintian Resurrection Release.
 .
   * Summary of tag changes:
     + Added:
       - alien-tag
       - chown-with-dot
       - conflicting-test-fields
       - declare-python-versions-for-test
       - drop-python-version-declaration
       - invalid-override-restriction
       - missing-prerequisite-for-pyproject-backend
       - old-devhelp-standard
       - stray-devhelp-documentation
       - test-leaves-python-version-untested
       - uses-poetry-cli
     + Removed:
       - crossing-screens
       - debhelper-compatibility-level-not-a-number
       - debian-tests-control-and-control-autodep8
       - exclusive-runtime-tests-field
       - package-contains-devhelp-file-without-symlink
 .
   [ Axel Beckert ]
   * Adopting Lintian. (Changes #1012289 from ITA to pure RFH.)
     + Remove Chris Lamb from Uploaders (see #1012289) and re-add myself.
   * Workarounds until
https://github.com/Perl-Critic/Perl-Critic/issues/925 is fixed:
     + Replace all occurrences of "Copyright ©" with "Copyright (C)" again.
     + Remove unnecessary usage of UTF-8 from bin/lintian.
     + Replace UTF-8 characters in mostly Copyright comments.
     + Replace UTF-8 characters in code with \N{…}.
   * Remove literal unicode character U+0334 COMBINING TILDE OVERLAY which
     likely had been added accidentally. (Triggered by the symptoms of
https://github.com/Perl-Critic/Perl-Critic/issues/925, but permanent.)
   * Update copyright years in debian/copyright.
   * Run perltidy over lib, bin/lintian, private/refresh-perl-provides,
     private/runtests and several files in t/scripts/.
   * data/…/perl-provides updated by running "debian/rules
     refresh-perl-provides".
   * Add Felix Lechner to debian/copyright based on copyright statements
     elsewhere. Thanks for all your contributions!
   * Update t/recipes/README: "debian/rules runtests" → "private/runtests"
   * Follow module renaming: Perl::Critic::Freenode → Perl::…::Community.
   * t/s…/h…/tag-coverage.t: Replace "$ENV{'LINTIAN_BASE'}" with
     "$ENV{'LINTIAN_BASE'} // '.'" to be able to run it with "prove -l".
   * init.d-general check: Avoid relying on line numbers in #DEBHELPER#
     replacement code.
   * very-long-line-length-in-source-file: Ignore files listed in new data
     file binary-file-extensions. (Closes: #1005046)
   * Fix false positives for adopted-extended-field with X- prefixed
     fields. (Closes: #999768)
     + Empty hints files seem to require a Test-Against field in desc.
   * Update own source lintian-overrides for "pointed hints".
     + Make them work with old and new lintian versions by using wildcards.
   * Rename README.developers to have a proper file suffix (.pod).
   * Switch syntax marker of README.developers.pod from "perl" to "pod".
   * Documentation update: Replace directory "frontend/" with "bin/".
   * Fix a bunch of "Use of uninitialized value $_ in concatenation"
     warnings when running tests with "prove -l" directly.
   * README.developers.pod: Explain the difference between check and test.
   * lintian(1): Drop mentioning of never existing --no-overrides option.
   * Replace unfitting Text::Glob with more flexible Regexp::Wildcards
     (Closes: #1003353)
     + Add unit test for Lintian::Util::match_glob. The current testsuite
       does not seem to be able to cover such a case.
   * Declare compliance with Debian Policy 4.6.1. (No changes needed.)
   * Refresh data using private/refresh-data. Skip unreleased policy though
     for now.
   * Fix "Use of uninitialized value $step in concatenation" in
     Lintian::Version which showed up as unrecognized tag (!) when running
     the test suite on the git repo already tagged for a release.
   * debian/gbp.conf: Declare so far used tag format so that gbp uses it.
   * Add lintian override for very-long-line-length-in-source-file in
     Lintian::Check::Cruft as well as test-leaves-python-version-untested.
   * Use versioned Breaks instead of Conflicts against lzd, see #1001655.
     Thanks Lintian for reporting ;-) and Paul Gevers for the sanity check!
 .
   [ Felix Lechner ]
   * Refresh manual references.
   * Use Text::Glob to match hint contexts with override patterns. Replaces
     a trusted homegrown routine. (Closes: #1003272)
   * Refresh list of available Debhelper commands.
   * Refresh list of installable fonts.
   * Generate section references for Lintian manual from repo; point to
     website.
   * Accept globbing patterns in profiles when enabling and disabling
     checks or tags.
   * Refresh data sources in parallel.
   * Add the New Maintainer's Guide to the list of quotable authorities.
   * Eliminate unpredictable output in the check siles/privacy-breach.
   * Honor the environment variable NO_COLOR as specified in
https://no-color.org/.
   * More attempts to eliminate unpredictable output in the check
     files/privacy-breach.
   * Drop the tag debian-tests-control-and-control-autodep8.
   * Set authority references apart from other data sources.
   * Provide rudimentary Emacs integration. (See: #968758)
   * Associate Emacs modules with the 'editors' archive section.
   * Recognize /usr/bin/raku as a known interpreter for scripts. (Closes:
     #1002828)
   * Do not depend on any particular Lzip implementation. (Closes:
     #1001655)
   * Exempt installables designated as documentation from warning about new
     Python2 packages. (Closes: #995286)
   * Update citations in two tags. (Closes: #1003131)
   * Drop version requirement from
     skip-systemd-native-flag-missing-pre-depends. (See: #1003271)
   * Import new CSS style sheet from the website.
   * Recognize dh-sequence-sphinxdoc as a valid prerequisite for
     dh_sphinxdoc. (Closes: #999810)
   * Tolerate multiarch acceptors in prerequisites for Debhelper commands
     and addons. (Closes: #1000234)
   * Issue yet more pointed hints.
   * Recognize pybuild-plugin-pyproject as a valid prerequisite for the
     python3 Debhelper plugin. (Closes: #1003668)
   * Exempt bullseye backports from changelog-file-missing-explicit-entry.
     (Closes: #941656)
   * Mask long source lines in autotools-generated files. (Closes: #996740)
   * Turn embedded-library into a classification tag. (Closes: #932634)
   * Require the targets build-arch and build-indep in debian/rules.
     (Closes: #657390)
   * Do not insist on a particular name for unversioned links to a shared
     library. (Closes: #963099)
   * Exempt the names of Debian folks associated with a package from
     spelling checks. (Closes: #989381)
   * Require py3version invocation consistent with presence of
     X-Python3-Version in d/control. (See: #1001677)
   * Exempt CGI scripts from executable-in-usr-lib. (Closes: #1003941)
   * CGI scripts can be ELF executables. (See: #1003941)
   * Exempt Python's .dist-info and .egg-info folders everywhere from
     documentation-outside-usr-share. (Closes: #1003913)
   * Flag an outdated Debian copyright just once; use the most recent
     year. (Closes: #1003817)
   * Implement '--no-show-overrides'; honor it for overrides and masks
     alike. (See: #1004240)
   * Allow the command-line option '--no-info' to reverse 'info=yes' in the
     configuration file. (Closes: #1004240)
   * Elide manual references to ancient Lintian versions; use modern
     examples. (Closes: #1004231)
   * Deprecate --no-tag-display-limit for '--tag-display-limit 0'; update
     documentation. (Closes: #1004239)
   * Also provide a default output width for
     lintian-annotate-hints. (Closes: #1004660)
   * Mask examples in tests from
     package-does-not-install-examples. (Closes: #1005184)
   * Recognize Java 18 in unstable, and Java 19 as otherwise
     available. (Closes: #1005762)
   * Leave default Java bytecode version at 56. (See: #1005762)
   * Adjust documentation reference to manual page for dh_make. (Closes:
     #1006390)
   * Warn about devhelp index files that use version 1. (Closes: #1006859)
   * Store ELF information from readelf in an MLDBM database. (Closes:
     #1003456)
   * Issue pedantic hint for dot in 'chown user.group' instead of a
     colon. (Closes: #1007140)
   * Upgrade missing-systemd-timer-for-cron-script to warning; no longer
     experimental. (Closes: #1007257)
 .
   [ Ryan Finnie ]
   * Provide a constant citation for
     systemd-service-file-uses-nobody-or-nogroup. (Closes: !385)
 .
   [ Louis-Philippe Véronneau ]
   * Check that tests pulling in all Python versions also query which ones
     are available. (Closes: !361)
   * Add new Python tags for pyproject.toml build backends according to
     PEP-517. (Closes: !384)
   * Rename 'python3-flit' to 'flit', as there is no 'python3-flit'
     package. (Closes: !386)
 .
   [ Daniel Kahn Gillmor ]
   * Correct lintian-annotate-hints manpage.
 .
   [ Simon McVittie ]
   * Silence a very widespread false positive for detached debug symbols.
     (Closes: #1000977, !387)
 .
   [ Simon Quigley ]
   * Add "kinetic" as a known Ubuntu distribution. (Closes: !392)
 .
   [ xiao sheng wen(肖盛文) ]
   * Add riscv64 support (Closes: #1012090, !394)
 .
   [ Damyan Ivanov ]
   * Update releases.json data for Debian policy releases (4.6.1 added;
     closes: !393)
 .
   [ Paul Wise ]
   * Add more obsolete domains for former source code hosting services.
Checksums-Sha1:
 863a51cffc5b8359ef133d6e6f150d9cac148eb3 2503 lintian_2.115.0.dsc
 e20194c63f481a7361969fab6ea7739f3f6e03d5 2170172 lintian_2.115.0.tar.xz
 3453b48f59dd2f58e2e78523e9018c58a42faebe 7274 lintian_2.115.0_source.buildinfo
Checksums-Sha256:
 431a025b52e185cac6cbf2fedca8b6c60e2f7dfa55d89d86fcd543a34e8232b9 2503 lintian_2.115.0.dsc
 f353d372d036daa6ad0341b418728cfe73c11688708b6c3a33d50acb445d2b53 2170172 lintian_2.115.0.tar.xz
 e1c1bd41b7f5a8014231f9db422c1711e97cf50146eab83a1d113370735f02d9 7274 lintian_2.115.0_source.buildinfo
Files:
 4484e31abe39a15def23b119f92ef3ab 2503 devel optional lintian_2.115.0.dsc
 9d7922b69d30a63693825120e049ea00 2170172 devel optional lintian_2.115.0.tar.xz
 12f2494d410df4c2bf03f82075ce5f60 7274 devel optional lintian_2.115.0_source.buildinfo
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEERoyJeTtCmBnp12Ema+Zjx1o1yXUFAmKwZiIACgkQa+Zjx1o1
yXUIng/5ARDjo8W4NggeM79xaeIgqtRbCao5XuBX6VyAE6hupaK8vHH/konnGmwg
jfRvPQK6YCXfqHggIKNQnToJgKUxdI+U3e10PYrbc5qt2UWFMiRfEHGqG3cfu+uA
JhqldKXfRkvmY4+9WPChWZ4C8qjdPZNcQwwdwm1Rg6gKMreYDGNIWJ94Hh7BkNsC
lNowSbDW6uE0XLBxVVeHhQGrn0Aki8fkx82W+Hod2A26sCXv/Gx7OSb8KVERa3+7
D05KDZd+ZGXBIdk/zRn/AeCxwcLXXMCS7qNDsfbJ8oUeYyy7y7QrQbGeFrBdOTyk
JbqqG0rTGbvfg3UcviOm/rvkr5QHdA5OMLUKRoljApMJEzbASGzYqNiUSmZNWH8x
v9EZ/qTHrcPFL/bIC9POvjD3FhSs3EkgQxXCuVPWZRruurgEme6DmnxHEj9TAe6L
GcUr+6DDHMw+j9SlO04VDDpUFVO2ftPfMcSckNCNM3eMxfig4XjPmyay3m6BjgaF
Rq6ckTUCUt5hsm7T48I0PAjXMRcAbemfI3PmVOUgwIf3BvzcdvJew0h90ULOY94N
cCWdsZ5SwC1hoz6EsBVmD16XxxYvZM7/wcf40PJkJ+YwtJu2Wm3dAv5WPK8UTrYr
qK1s62DfByho45eV9rXKeLnjvRN37rQYOWl7WwYy6YfpzQYDFWU=
=3dK3
-----END PGP SIGNATURE-----