Hi!

On Tue, 2024-05-14 at 18:19:18 +0000, Ben Ferreri wrote:
> Package: dpkg
> Version: 1.22.6
> Severity: normal
> X-Debbugs-Cc: bferr...@intwineconnect.com

> When attempting to install a package as a non-superuser, the configured
> pre-invoke hook runs, but the post-invoke hook does not. I believe that
> either both hooks should run in this case or neither should.
> 
> For example:
> 
> I have configured both a pre-invoke and post-invoke hook in
> /etc/dpkg/dpkg.cfg.
> I attempt to install a package as a non-root user with `dpkg -i
> mypackage.deb`. The command fails, as expected. However, I observe 
> that the pre-invoke hook has run, but the post-invoke hook has not run.
> 
> I would have expected that if the pre-invoke hook ran, the post-invoke
> hook should also have run.

Ah, indeed. Thanks for the report. I've got this fixed locally, but
I'll ponder a bit more about the correct semantics, when combined with
--force-not-root. For --no-act/--dry-run I think it's clear they
should not be executed though.

Thanks,
Guillem

Reply via email to