Community Packages

Please read this before reporting a bug:

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!

FS#60107 - [packagekit] libpk_backend_alpm ignores custom libalpm hooks

Attached to Project: Community Packages
Opened by Sergey Zolotorev (serzh-z) - Tuesday, 18 September 2018, 14:31 GMT
Last edited by Eli Schwartz (eschwartz) - Thursday, 20 September 2018, 05:06 GMT
Task Type Bug Report
Category Upstream Bugs
Status Assigned
Assigned To Christian Hesse (eworm)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 0%
Votes 1
Private No



PackageKit (libpk_backend_alpm) ignores /etc/pacman.d/hooks/*.hook while running from GNOME Software/Updates.

It is a critical bug if you have some hooks which build/copy/patch kernels or update boot loader entries etc.

Additional info:
* Version: 1.1.10-2
* Default /etc/pacman.conf and /etc/PackageKit/alpm.d/pacman.conf

Steps to reproduce:

1. Create simple hook /etc/pacman.d/hooks/test.hook:

Operation = Install
Operation = Upgrade
Type = File
Target = *

Description = TEST
When = PostTransaction
Exec = /bin/bash -c 'while read -r f; do printf "$(date) ${f}\n" >> /var/tmp/pacman-hook-test.txt; done'

2. Run GNOME Software and confirm to update/reboot system.

3. Wait for update finished and check /var/tmp/pacman-hook-test.txt - there is no file.

[4. Run regular `pacman -S ...` and check /var/tmp/pacman-hook-test.txt - now it exists]
This task depends upon

Comment by Eli Schwartz (eschwartz) - Thursday, 20 September 2018, 05:06 GMT
  • Field changed: Category (Packages → Upstream Bugs)
The packagekit libalpm backend ignores lots of things... FS#45709 shows it ignores IgnorePkg too.

I'm assuming this is an upstream "feature parity" bug and packagekit needs to learn how to handle the configuration file and process the settings it passes on to libalpm function calls. Pretty sure this is not merely something wrong with how we package packagekit itself.
Comment by Sergey Zolotorev (serzh-z) - Thursday, 20 September 2018, 08:44 GMT
Eli, does it mean that users should not place custom ALPM hooks to /etc/pacman.d/hooks (when they run ALPM via PackageKit) and must use /usr/share/libalpm/hooks directory instead?