930 Commits

Author SHA1 Message Date
Paul Gevers
bee197f085
policy/autopkgtest Add minor comments 2017-09-08 11:08:22 +02:00
Paul Gevers
278b3dcdd0
autopkgtest: switch from testing=series to testing=testing 2017-09-08 11:08:22 +02:00
Paul Gevers
5ae8ccbcc6
Get the autopkgtest test suite to run with Debian's britney
* test_autopkgtest: use --no-compute-migrations instead of removing UPGRADE_OUTPUT
* comment out some tests that I can't get to work in Debian, while all but three work if
  run inside Ubuntu's britney
2017-09-08 11:07:04 +02:00
Paul Gevers
77bb15e0e8
Plug in the new autopkgtest policy 2017-09-08 11:06:33 +02:00
Paul Gevers
4dda7b6e7e
Add britney option: --series
- autopkgtest tests rely on it
- Ubuntu uses this
2017-09-08 11:06:20 +02:00
Paul Gevers
2bce9e334e
Initial commit for autokpgtest
* copy of Ubuntu's version at 593acb2753ce167ed4d2dec0091702315e89e705
* merge tests/__init__.py with Ubuntu's (that only contained autopkgtest)
2017-09-08 10:25:16 +02:00
Adam D. Barratt
3220710a6c britney.py: stop referring to the freeze policy while we're not frozen
Signed-off-by: Adam D. Barratt <adam@adam-barratt.org.uk>
2017-09-08 07:43:11 +00:00
Niels Thykier
d3b90e754b britney: Rewrite conditional assignment
The original method confused IntelliJ into thinking that binary_t was
a boolean rather than an object.

Signed-off-by: Niels Thykier <niels@thykier.net>
2017-09-02 11:10:58 +00:00
Niels Thykier
8352d62999 Improve bug example and avoid usage of "RC"
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-08-26 17:29:52 +00:00
Niels Thykier
7e2c62a600 Avoid gendered pronoun for britney
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-08-26 17:17:22 +00:00
Niels Thykier
e2cbe15157 Improve documentation based on review in #d-release
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-08-26 15:18:48 +00:00
Niels Thykier
cb5d888733 doc: Document basic migration handling/debugging
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-08-26 14:09:19 +00:00
Niels Thykier
1042c626ec excuse: Improve text for REJECTED_NEEDS_APPROVAL
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-08-26 12:53:20 +00:00
Niels Thykier
77d737cefe doc/hints.md: New doc based on the RT README for hints
There is no reason why the hint documentation is not in the britney
code base (particularly, as we would be more likely to update it when
we add new hints).

Signed-off-by: Niels Thykier <niels@thykier.net>
2017-08-13 19:25:08 +00:00
Niels Thykier
2692b503d4 Drop auto-generated doxygen documentation
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-08-13 17:13:08 +00:00
Niels Thykier
6e022eed54 test: Add test for a bug I was about to introduce
When I rewrote the compute_scc function into an iterative variant, I
almost included a bug that could make it come up with components that
were not strongly-connected.

Signed-off-by: Niels Thykier <niels@thykier.net>
2017-07-29 08:05:52 +00:00
Niels Thykier
69473eefca solver: Extract compute_scc into a function
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-07-29 07:54:48 +00:00
Niels Thykier
bd375fdd85 solver: Make _compute_scc iterative
Rewrite _compute_scc to be iterative to avoid call recursion limit for
graphs with long dependency chains.

Signed-off-by: Niels Thykier <niels@thykier.net>
2017-07-29 07:40:15 +00:00
Niels Thykier
64653087d0 solver: Fix bug where some items were not emitted
Sometimes the solver would correctly compute which items are grouped
together, but then fail to emit some groups.  This is trivially
fixable by forcing an update of "before" + "after" relations.
Admittedly, this looks unnecessary, so it may just be hiding the bug.

Nonetheless, the change makes the new test_solver_simple_scc test
produce the expected result.

Signed-off-by: Niels Thykier <niels@thykier.net>
2017-07-28 21:36:01 +00:00
Jonathan Wiltshire
981b9333f6 Revert "Implement a mandatory 10 day migration delay"
This reverts commit 0349cd94774d4f7ba675570bb406fb0dbb21ef5f.

Signed-off-by: Jonathan Wiltshire <jmw@debian.org>
2017-06-19 19:11:13 +00:00
Ivo De Decker
363f51fd3b Give myself force and force-hint
Signed-off-by: Ivo De Decker <ivodd@debian.org>
2017-04-09 09:41:20 +00:00
Niels Thykier
5021053db5 Support doing migration-less runs
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-04-08 06:21:26 +00:00
Niels Thykier
189edf42ec britney: Move britney's start of day to 7 pm
In preparation for running Britney 4 times a day and we wanting the
22:00 UTC run to do the aging.

Signed-off-by: Niels Thykier <niels@thykier.net>
2017-04-08 06:21:26 +00:00
Raphaël Hertzog
57bc721f50 Document new files required by PiupartsPolicy 2017-04-07 13:08:46 +02:00
Raphaël Hertzog
e3323d9a67 Rename FUCKED_ARCHES into OUTOFSYNC_ARCHES in template configuration file
Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
2017-04-07 13:08:46 +02:00
Niels Thykier
f6120e5ec3 Use the correct required age in html excuses
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-03-19 18:01:35 +00:00
James McCoy
0c44d3ac27 excuse: Add an EOL to the verdict summary line in HTML output
devscripts' grep-excuses expects each <li> to be on its own line.  When
d7a676d0741729bb643e0b8c54b989cb747c6a4b added the verdict summary,
without an EOL, it broke grep-excuses' ability to search by maintainer.

Signed-off-by: James McCoy <jamessan@debian.org>
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-25 06:54:14 +00:00
Niels Thykier
67c784f796 excuse: Use verdict name rather than object in excuses.yaml
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-14 07:36:54 +00:00
Niels Thykier
9ca5f7e24e Add more verdicts to provide more detailed excuses
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-13 19:37:53 +00:00
Niels Thykier
d7a676d074 Aggregate all migration decisions and present it in excuses
With this change, Britney can now provide a very brief summary of the
migration via one single value (YAML) or line (HTML).  This solves two
issues:

 * It provides an aggregated version of the policy decision without
   having to loop over all policies (and even those would not give
   a full verdict on their own as not all rejections come from
   policies)

 * It enables a simple way to inform readers of the HTML excuses of
   whether a rejection is permanent or not.  This should hopefully
   make it easier for contributors to understand Britney and react
   more pro-actively.

Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-13 19:37:53 +00:00
Niels Thykier
f40a7f41b3 Replace dontinvalidate with forced
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-13 19:37:53 +00:00
Niels Thykier
6e560c854a Only show the first (relevant) remove hint in excuses
In the unlike case that there are multiple removal hints, showing
the first valid hint should be sufficient.

Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-13 19:37:53 +00:00
Niels Thykier
045ce2bf7b britney: Don't show "fake" packages in excuses
They are implementation details and should not appear in the excuses.

Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-13 19:37:53 +00:00
Niels Thykier
b34ac3bdd9 Add a verdict field to all policies with the actual verdict
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-13 19:37:53 +00:00
Niels Thykier
552e82c3dc tests/test_policy.py: refactor test cases
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-13 19:37:53 +00:00
Niels Thykier
5f2a84a4f8 Remove redundant if-else - if branch is always true
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-13 19:37:53 +00:00
Niels Thykier
42be17ad26 inst-tester: Correctly handle unresolved essential choices
Britney has a special case for essential packages to ensure that any
package that with essential packages are not installable.  This check
did not account for a case, where a package is not co-installable with
two or more pseudo-essential package part of the same OR dependency.
A contrived example based on real world data:

  Package: foo
  # Conflict with all providers of "awk"
  Conflicts: mawk | gawk | original-awk

This alone is actually not sufficient to trigger the bug, as
_get_min_pseudo_ess_set is in theory some times smart enough to pick
an "obvious" solution between the pseudo-essential option.
  When it does, one of the above ends up in the (de-facto) essential set
and then the installability tester correctly rejects "foo".

Though, even with the fix above, the handling for this is probably not
correct if the essential set is not (fully co-)installable.  However,
that basically only happens if we are bootstrapping an architecture
(or testing is royally broken, in which case this is the least of our
worries).

Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-11 11:08:52 +00:00
Niels Thykier
337d548edb tests: add some unit tests of installability tester
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-11 11:07:07 +00:00
Niels Thykier
f9c643537c britney: add ignore-rc-bugs hint to HINTS_HELPERS
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-02-03 16:47:24 +00:00
Niels Thykier
ed2a34e897 hints.py: Fix incorrect documentation of min_args parameter
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-01-29 12:58:14 +00:00
Niels Thykier
3c33818499 tests: add test case for parsing aliased hints
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-01-29 12:56:50 +00:00
Niels Thykier
ee12b76885 tests: Add test for some invalid hints
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-01-29 12:56:50 +00:00
Niels Thykier
1fcccea83f tests: Extract some common test utils to tests/__init__.py
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-01-29 12:14:49 +00:00
Niels Thykier
61bdee0fa7 Upload code coverage results to codecov.io
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-01-29 11:06:43 +00:00
Julien Cristau
608ce0e9d2 Fix logging of conflicting hints
Not all hints have a 'days' attribute.

Signed-off-by: Julien Cristau <jcristau@debian.org>
2017-01-29 11:14:55 +01:00
Iain Lane
ccfd61cf6a hint-tester: Don't lowercase the input
Doing this means that you can't use the hint tester for packages with
uppercase characters in the version, e.g.

  Version mismatch, dreamchess 0.2.1-rc2-2build1 != 0.2.1-RC2-2build1

Closes: Debian#846141
Signed-off-by: Niels Thykier <niels@thykier.net>
2017-01-29 08:38:39 +00:00
Jonathan Wiltshire
3156b2c753 Fix call to super() in SimplePolicyHint
Signed-off-by: Jonathan Wiltshire <jmw@debian.org>
2017-01-29 01:17:53 +00:00
Niels Thykier
cd5e253b9c Revert "Give myself block-all hint"
This reverts commit e296dd843ead67e73d04d0bf2af75b0c9935423a.
2017-01-07 09:04:40 +00:00
Niels Thykier
e296dd843e Give myself block-all hint
... until we get write access to the freeze hints

Signed-off-by: Niels Thykier <niels@thykier.net>
2017-01-06 07:30:55 +00:00
Emilio Pozuelo Monfort
af7c96142d Add ignore-piuparts to the standard hint set
Signed-off-by: Emilio Pozuelo Monfort <pochu@debian.org>
2016-12-09 08:59:56 +01:00