New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AptTool: add repo key before running apt-add-repository (#8857) #8861
AptTool: add repo key before running apt-add-repository (#8857) #8861
Conversation
As described in #8857, this proposed change will have AptTool running an extra index update, which does waste some time. However:
The version of |
Looks like I'm running afoul of some expected command sequences in the test suite. I'll check those in a little while. |
In Ubuntu 20.04 (and maybe earlier), the behavior of apt-add-repository 'deb https://example.com/repo example main' is to add the named repository to apt's sources *and* to update the package index. If the new repository's package key is not already in apt's keyring, this will fail. It is possible to change this behavior by running apt-add-repository -n, but adding the key before running apt-add-repository also works, doesn't require new command-line switches, and should be backwards-compatible with apt-add-repository versions that might not behave as described above.
dcb45f6
to
73533a8
Compare
Note for the reviewers:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the added time is reasonably low and probably we don't have a "safer" way to do it without breaking. For me, it could be merged.
Changelog: Bugfix: AptTool: add repo key before running apt-add-repository.
Docs: omit
Closes #8857
In Ubuntu 20.04 (and maybe earlier), the behavior of
is to add the named repository to apt's sources and to update the
package index. If the new repository's package key is not already in
apt's keyring, this will fail.
It is possible to change this behavior by running apt-add-repository -n,
but adding the key before running apt-add-repository also works, doesn't
require new command-line switches, and should be backwards-compatible
with apt-add-repository versions that might not behave as described
above.
develop
branch, documenting this one.Note: By default this PR will skip the slower tests and will use a limited set of python versions. Check here how to increase the testing level by writing some tags in the current PR body text.