Radish alpha
r
rad:zwTxygwuz5LDGBq255RA2CbNGrz8
Radicle CI broker
Radicle
Git
RSS Sort broken
Closed { reason: Solved } seam345-little-my-CI opened 9 months ago

On the main RSS the entires are limited to 10, to select the top 10 it is first sorted by the pub_date key items.sort_by_key(|item| item.pub_date().map(|s| s.to_string()));. However this date is formated with rfc 2822 so it’s starting with the day of the week “mon/tue/…” resulting in the sort making no sense, when it should be sorting by latest first.

liw commented 9 months ago

Argh.

Good catch. Thank you. I always use ISO8601 and I blithely assumed that was the case where, when I wrote the sorting. And I failed to add a unit test to verify the sorting, too.

liw commented 9 months ago

And of course I now see I wrote the code to generate an RFC 2822 time stamp. So much fail.

liw commented 9 months ago

Made a patch to fix this: 7e2ccf45c9c7c93954ee9874584a5c9226e6b7fe

liw commented 9 months ago

Couldn’t figure out an easy way to set up a test for this, though.