Gentoo Archives: gentoo-dev

From: Gilles Dartiguelongue <eva@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] RFC: Repoman to warn about suspicious =-dependencies
Date: Mon, 26 Mar 2018 09:29:20
Message-Id: 1522056537.27899.7.camel@gentoo.org
In Reply to: [gentoo-dev] RFC: Repoman to warn about suspicious =-dependencies by "Michał Górny"
1 Le dimanche 04 mars 2018 à 12:37 +0100, Michał Górny a écrit :
2 > Hi, everyone.
3 >
4 > I have proposed a new check for repoman [1] (with a patch at [2])
5 > that
6 > would warn developers about suspicious '=' deps.
7 >
8 > By suspicious, I mean dependencies '=foo-1.2.3' which are sometimes
9 > mistakenly used instead of '~foo-1.2.3', and cause some degree of
10 > mayhem
11 > when someone revbumps the package (either by preventing people from
12 > upgrading or causing depgraph breakage).
13 >
14 > The check would trigger whenever '='-class dependency is used without
15 > a revision specified and without the '*' suffix. It would suggest to
16 > either use '~' operator when any revision is acceptable, or
17 > explicitly
18 > specify '-r0' (which is equivalent to no revision specified).
19 >
20 > In other words, repoman would complain at:
21 >
22 > =dev-foo/bar-1.2.3
23 >
24 > but it will be happy if you used:
25 >
26 > ~dev-foo/bar-1-2.3
27 > =dev-foo/bar-1.2.3-r0
28 >
29 > I think this cause the trouble of specifying '-r0' rather rarely, and
30 > it
31 > will decrease the number of mistakes, also effectively making Gentoo
32 > development easier. It is somewhat inspired by the handling of slot
33 > operators (where repoman explicitly asks you to use ':*' instead
34 > of no operator when the latter would be ambiguous).
35 >
36 > What do you think?
37
38 Sounds good. The attached script hopefully gives a good indication of
39 how much packages would be affected. A local run raises about 92
40 ebuilds.

Attachments

File name MIME type
list-pinned-deps.py text/x-python
signature.asc application/pgp-signature