Gentoo Archives: gentoo-dev

From: Alec Warner <antarus@g.o>
To: Gentoo Dev <gentoo-dev@l.g.o>
Subject: Re: [gentoo-dev] Re: Deleting old news items
Date: Sat, 06 Jan 2018 18:13:08
Message-Id: CAAr7Pr-Y9RHoG6EchpM5FZetmrDpnvX2JiCaFjao5LfDPEyQdg@mail.gmail.com
In Reply to: Re: [gentoo-dev] Re: Deleting old news items by Ciaran McCreesh
1 On Sat, Jan 6, 2018 at 11:25 AM, Ciaran McCreesh <
2 ciaran.mccreesh@××××××××××.com> wrote:
3
4 > On Sat, 6 Jan 2018 08:18:19 -0500
5 > kuzetsa <kuzetsa@×××××.com> wrote:
6 > > On 01/06/2018 05:05 AM, Ulrich Mueller wrote:
7 > > >>>>>> On Sat, 6 Jan 2018, Duncan wrote:
8 > > >> $ equery b news.eselect
9 > > >> app-admin/eselect-1.4.10 (/usr/share/eselect/modules/news.eselect)
10 > > >> So in that case it's not the PM, but eselect.
11 > > > In fact, it is the PM that would do the filtering, before filling
12 > > > the list of unread news items
13 > > > in /var/lib/gentoo/news/news-gentoo.read.
14 > > >
15 > > > Filtering in eselect news would be problematic: Obtaining the list
16 > > > of items with "eselect news list" and e.g. reading them with
17 > > > "eselect news read" are issued as separate commands, which requires
18 > > > that the list of valid items does not change. However, time-based
19 > > > filtering could cause a race condition, like an item expiring
20 > > > between execution of the two commands.
21 > >
22 > > The race condition could be addressed by issuing a warning
23 > > at or around the time when expirations occur (midnight),
24 > > with or without detecting specific expirations which may
25 > > have occurred:
26 >
27 > How accurate is "around"? Obviously we'd need to introduce a user
28 > configuration option so different users could set appropriate values
29 > for their needs.
30 >
31 > Seriously though, all this complexity is just highlighting that dates
32 > are a really bad way of deciding when a news item should expire, and
33 > that if we need anything, it's more Display-If conditions.
34 >
35 >
36 I rescind my patches; I'm fairly sure portage is broken and I don't really
37 relish fixing it; I've already spent more than 2 hours working on this and
38 this isn't worth spending more time on anyway.
39
40 -A
41
42
43
44 > --
45 > Ciaran McCreesh
46 >
47 >