OK, the reason this happens is that some of your key files are not readable (I'm not sure, but it might be running as _apt). The commit mentioned introduced a regresssion in that it does not ignore failures from unreadable key files.
This was fixed in 1.3~rc3 in commit 105503b4b470c124bc0c271bd8a50e25ecbe9133. I cherry-picked that change in my for-1.2/apt-key branch in https://github.com/julian-klode/apt. You should be able to verify this by adding -o Dir::Bin::Apt- Key="$PWD/build/bin/apt-key" to the apt-get invocation in the script and then running it once with the normal 1.2.y branch and once with my for-1.2/apt-key branch. The test suite currently fails, as the new tests added depend on some other changes, once I got those merged I can upload it as 1.2.17 (1.2.16 is already in the unapproved queue for -proposed, it fixes bugs with localized strings in protocols). ** Also affects: apt (Ubuntu Xenial) Importance: Undecided Status: New ** Changed in: apt (Ubuntu Xenial) Status: New => Triaged ** Changed in: apt (Ubuntu) Status: New => Fix Released -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1642386 Title: At least one invalid signature was encountered. To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/apt/+bug/1642386/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs