bzip2/bunzip2 was missing in the snap, which prevented "git ubuntu
import" from working in the case that bzip2 compression was used in
their source packages.
Add an integration test to ensure that all dpkg decompressors are
available, and fix the snap to include them explicitly.
An internal "reconstruct changelog" implementation is used by "git
ubuntu merge". However, the original shell implementation still exists
and is exposed by a separate endpoint. In the recent snap refactoring to
core20, this implementation was broken by the new wrapper failing to
pass through the command line arguments. We fix this, and also add a
test to ensure this doesn't regress.
The test is somewhat involved because there are multiple ways in which
this (and our other endpoints) are invoked, and we want to test them
all. More details in the comments.
I fixed update-maintainer for the snap in commit b530026, but didn't fix
the dependency in the deb. This adds an integration test that revealed
that problem, and adds the required dependency in the deb, too.
I noticed that we have one for awk, but not for sed, even though sed is
needed by some components. This test follows the same pattern set by the
previous awk test.
I suppose I could parameterise sed/awk and combine the tests, but while
there are only two, they're right next to each other and only a few
lines, it doesn't seem worth the minor additional complexity.
There should be two spaces between the email address and the date. This
fixes warnings when using dpkg-buildpackage which can be seen in
captured test output when tests fail for other reasons. Making this
change gets rid of the noise in that case.
Since source_builder is test infrastructure and not used in production,
it doesn't make sense to "test the tests" yet we can be assured that
nothing functional is impacted by this change. Further, since tests
still pass, we know that tests aren't regressed either.
Allow uploaders to specify where rich history associated with an upload
can be found directly from the changes file. This allows rich history to
be provided by any uploader without concern for things like access
control for pushing upload tags.
This partly deprecates upload tags. The generally recommended approach
to supply rich history will be through the changes file. Upload tags
remain to preserve the rich history preservation mechanism on reimport.
After a transition to changes file based rich history is complete, we
might refactor the rich history preservation mechanism and then drop
support for upload tags altogether. However it might be useful to retain
upload tag support for testing purposes, as they are easier to arrange
than this new changes file mechanism.
For the retry logic, we add a dependency on tenacity. This module seems
to be the most widely used for this purpose, and is already in main in
Ubuntu Focal.
The underlying Launchpad source_package_publishing_history object may
contain a reference to a changes file associated with an upload. Add a
method to access this through the SourcePackageInformation object if it
exists.