Unable to read cache information: ("Connection broken: PermissionError(13, 'Permission denied')", PermissionError(13, 'Permission denied'))
Closed this issue · 6 comments
On two different machines I have this error every time I run informant check
:
$ informant check
ERROR: Unable to read cache information: ("Connection broken: PermissionError(13, 'Permission denied')", PermissionError(13, 'Permission denied'))
ERROR: Encountered feed error: <unknown>:6:-1: Opening and ending tag mismatch: hr line 6 and body
WARN: no news feed items, informant is performing no action
What could be the cause of this? Thank you!
It seems like the news feed itself might be having issues? Maybe with command line clients only? The web page seemed to load, but trying to curl the feed gave me a "too many requests" error.
I found it, there's a new redirect from https://archlinux.org/feeds/news
to https://archlinux.org/feeds/news/
(notice trailing slash).
I'll have an update together to fix this a little later.
New update should take care of the issue, but you might need to run informant --clear-cache check
to clear out the permission error.
Awesome, thank you so much!
New update should take care of the issue, but you might need to run
informant --clear-cache check
to clear out the permission error.
My scenario: Installed informant and added myself to the informant
group – as per post-install message; but as I dread rebooting I used it with root
some times before system reload. The result was that I had a lock file in /var/cache/informant/...
that only had read permissions by informant after reboot. Resulting in (as shown by strace
- only mentioning as that was how I found the culprit):
openat(AT_FDCWD, "/var/cache/informant/6/c/0/1/e/012fbc....lock", O_RDWR|O_CREAT|O_TRUNC|O_CLOEXEC, 0644) = -1 EACCES (Permission denied)
ERROR: Unable to read cache information: ("Connection broken: PermissionError(13, 'Permission denied')", PermissionError(13, 'Permission denied'))
or by ls -la /var/cache/informant/6/c/0/1/e/
:
-rw-r--r-- 1 root informant 0 Oct 2 15:09 012abc....lock
Tested a sudo informant read
after boot and then I get:
-rw-rw-r-- 1 root informant 20K Oct 6 11:13 0123abc...
-rw-r--r-- 1 me informant 0 Oct 6 11:13 0123abc....lock
Not sure; but one could perhaps tweak the permission hierarchy or give a message saying one need to do a clearing of cache on reboot if used with root (yes, that is wonky to explain). Or perhaps a note in the manual on --clear-cache
... not sure .... as one can clear the cache as the directory itself has proper rights for informant
.
The file correctly has the informant group, just wrong permissions...
I'll try to see if there's a CacheControl option for that, if not hopefully setting the correct umask in python before CacheControl runs will do the trick.