Hi! On Tue, 2016-01-05 at 07:33:49 +0800, 積丹尼 Dan Jacobson wrote: > Package: dpkg > Version: 1.18.4 > Severity: wishlist
> Wouldn't it be best that > # dpkg -i a.deb b.deb c.deb > first be sure that we even have each deb specified on the command line > before proceeding? I can do that. Given that I'd like to move some of the checks and control member extraction to an early phase, this goes in that direction. > OK, and I suppose also check that their checksums are OK. The checksums are not known to dpkg, those come from the repository information and that is only known to apt, which dpkg is obvlivious of. > I mean doing that would never do any harm. > It wouldn't even use more CPU, because you are going to have to do those > checks sooner or later during the run. It does use slightly more time, because currently we don't check if they exist, we just open them, and if that fails, we know from the system it does not exist. On Tue, 2016-01-05 at 07:55:00 +0800, 積丹尼 Dan Jacobson wrote: > One might argue that it is the user's fault for mistyping file names. > But let's think in term of checksums. Do we proceed further with a .deb > if there is some problem with its checksum? No. Even though the checksum > might refer to 1000 files, only one of which has a problem. > > So checking that all .debs given on the command line are OK first is the > same principle: > > During the run, we are going to do Check 1 Install 1 Check 2 Install > 2.... > > So why not Check 1 Check 2 Install 1 Install 2...? > > It only follows the same principle, Unpack 1 Unpack 2... Setup 1 Setup > 2... that you already do. Sure, I can agree with the principle above, but currently it might not be possible to perform all checks that would be ideal. Those will be coming in the future piece by piece. Thanks, Guillem

