On 01/06/2018 05:05 AM, Ulrich Mueller wrote: >>>>>> On Sat, 6 Jan 2018, Duncan wrote: >> $ equery b news.eselect >> app-admin/eselect-1.4.10 (/usr/share/eselect/modules/news.eselect) >> So in that case it's not the PM, but eselect. > In fact, it is the PM that would do the filtering, before filling the > list of unread news items in /var/lib/gentoo/news/news-gentoo.read. > > Filtering in eselect news would be problematic: Obtaining the list > of items with "eselect news list" and e.g. reading them with "eselect > news read" are issued as separate commands, which requires that the > list of valid items does not change. However, time-based filtering > could cause a race condition, like an item expiring between execution > of the two commands. > > Ulrich
The race condition could be addressed by issuing a warning at or around the time when expirations occur (midnight), with or without detecting specific expirations which may have occurred: WARNING: [n] is about to / has expired, and the list order is about to / has just changed (as appropriate for list and read respectively) Otherwise just warn when the commands run near midnight.
signature.asc
Description: OpenPGP digital signature