Package Details: informant 0.6.0-1

Git Clone URL: https://aur.archlinux.org/informant.git (read-only, click to copy)
Package Base: informant
Description: An Arch Linux News reader and pacman hook
Upstream URL: https://github.com/bradford-smith94/informant
Keywords: news
Licenses: MIT
Submitter: bradford-smith94
Maintainer: bradford-smith94
Last Packager: bradford-smith94
Votes: 111
Popularity: 4.60
First Submitted: 2018-02-27 18:54 (UTC)
Last Updated: 2024-09-02 23:58 (UTC)

Pinned Comments

bradford-smith94 commented on 2024-04-30 01:59 (UTC) (edited on 2024-04-30 02:01 (UTC) by bradford-smith94)

After a major Python upgrade informant will break with an error likely including something like:

importlib.metadata.PackageNotFoundError: No package metadata was found for informant

This is inconvenient and not ideal, as it will cause all following pacman commands to fail. But since the version of Python that informant was built against is no longer there, this is the way it will be.

In this case, informant simply needs to be rebuilt against the newest Python version. Please do not flag the package out of date. Since v0.4.6 and upgrade/install (rebuild) of just informant itself should not trigger the hook, so you may be able to just force a rebuild of informant. However, this will still fail if rebuilding informant requires pacman to install makedepends. In that case: informant does not block removes, so first run sudo pacman -R informant and then reinstall informant (make sure it forces a rebuilt and doesn't reinstall a cached version).

Further discussion of the Python major version update causing errors can be found at the Github issue: https://github.com/bradford-smith94/informant/issues/40.

Latest Comments

1 2 3 4 5 Next › Last »

queenbiscuit311 commented on 2024-04-30 06:46 (UTC)

@bradford-smith94 that has indeed cleared it up, it's all working now

bradford-smith94 commented on 2024-04-30 01:59 (UTC) (edited on 2024-04-30 02:01 (UTC) by bradford-smith94)

After a major Python upgrade informant will break with an error likely including something like:

importlib.metadata.PackageNotFoundError: No package metadata was found for informant

This is inconvenient and not ideal, as it will cause all following pacman commands to fail. But since the version of Python that informant was built against is no longer there, this is the way it will be.

In this case, informant simply needs to be rebuilt against the newest Python version. Please do not flag the package out of date. Since v0.4.6 and upgrade/install (rebuild) of just informant itself should not trigger the hook, so you may be able to just force a rebuild of informant. However, this will still fail if rebuilding informant requires pacman to install makedepends. In that case: informant does not block removes, so first run sudo pacman -R informant and then reinstall informant (make sure it forces a rebuilt and doesn't reinstall a cached version).

Further discussion of the Python major version update causing errors can be found at the Github issue: https://github.com/bradford-smith94/informant/issues/40.

bradford-smith94 commented on 2024-04-30 01:50 (UTC)

@queenbiscuit311

Try with the newest version (0.5.1), I replaced the subprocess ps call with psutil, hopefully that avoids the issue you experienced.

queenbiscuit311 commented on 2024-04-29 23:00 (UTC)

Trying to set this up on a newly-installed system, it just keeps giving me this every time I try to use pacman:

(1/1) Checking Arch News with Informant ...
fatal library error, lookup self
Traceback (most recent call last):
  File "/usr/bin/informant", line 33, in <module>
    sys.exit(load_entry_point('informant==0.5.0', 'console_scripts', 'informant')())
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/site-packages/informant/informant.py", line 170, in main
    check_cmd(feed)
  File "/usr/lib/python3.12/site-packages/informant/informant.py", line 74, in check_cmd
    running_from_pacman = ui.running_from_pacman()
                          ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/site-packages/informant/ui.py", line 79, in running_from_pacman
    p_name = subprocess.check_output(['ps', '-p', str(ppid), '-o', 'comm='])
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/subprocess.py", line 466, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/subprocess.py", line 571, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['ps', '-p', '139751', '-o', 'comm=']' returned non-zero exit status 1.
error: command failed to execute correctly
error: failed to commit transaction (failed to run transaction hooks)
Errors occurred, no packages were upgraded.

Rebuilding doesn't seem to fix it either.

kullfar commented on 2024-04-28 08:52 (UTC) (edited on 2024-04-28 08:53 (UTC) by kullfar)

or just

yay -R informant

yay -S informant

It will "fix" exceptions

aydintb commented on 2024-04-28 08:00 (UTC)

yesterday, after the recent python updates, Informant failed during the system update.

Simply, when "pacman -Syu" is applied, the informant failed.

I removed the "hook" and re-run "yay -Syu", then created the "hook" again.

it seems that solved the problem for the moment.

furrykef commented on 2024-04-27 22:45 (UTC)

Somebody flagged this package, but I think it still works fine. If you're getting a message about "No package metadata was found for informant", you need to rebuild and reinstall the package. The same probably goes for many other AUR packages that use Python.

jongeduard commented on 2023-05-17 19:24 (UTC) (edited on 2023-05-17 19:27 (UTC) by jongeduard)

Hi! Today I noticed that Informant shows me an extra error message "Max retries exceeded with url" starting with "ERROR:" in uppercase red colored letters, just before it came up with the intended actual news interruption.

See below for the fragment of terminal output which makes it clear.

How do I need to interpret this? Is this a tiny issue in Informant or is it really just some weird short during internet connection issue that I was experiencing?

(...)
(1/4) Checking Arch News with Informant ...
ERROR: Unable to read cache information: HTTPSConnectionPool(host='archlinux.org', port=443): Max retries exceeded with url: /feeds/news/ (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7ff5d6c5e950>: Failed to establish a new connection: [Errno -2] Name or service not known'))
:: informant: Stopping upgrade to print news
Git migration announcement
Mon, 15 May 2023 19:50:21 +0000

This Friday morning (2023-05-19) the Git packaging migration will start until Sunday
(...)

FranklinYu commented on 2023-05-17 15:34 (UTC) (edited on 2023-05-17 15:34 (UTC) by FranklinYu)

Do I understand it correctly that this (broken hook) applies to any AUR package that adds pacman hooks, not only informant?

(To be more precise, it would only happen to locally-built packages, be it AUR or not.)

jongeduard commented on 2023-05-06 21:10 (UTC)

@tocic

Thanks! I was having this Python error, followed by an exception trace with details.

In my case simply uninstalling was enough to see no error anymore. Turns out that it happened on package installation, not the actual build. However, just to be sure I decided to do one more time and also rebuild the thing.