From 9a78884eaad3cac0061ef9e47106cb509de541f1 Mon Sep 17 00:00:00 2001 From: Jake Walker Date: Mon, 27 Jan 2025 19:23:57 +0000 Subject: [PATCH] fix guids --- Cargo.toml | 1 - src/main.rs | 9 +-------- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 7104258..0c34c85 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,4 +9,3 @@ chrono = { version = "0.4.39", default-features = false, features = ["now"] } kuchikiki = "0.8.2" reqwest = { version = "0.12.12", features = ["blocking"] } rss = { version = "2.0.11" } -uuid = { version = "1.12.1", features = ["v7"] } diff --git a/src/main.rs b/src/main.rs index 6294ced..5a30946 100644 --- a/src/main.rs +++ b/src/main.rs @@ -5,7 +5,6 @@ use chrono::{Datelike, Days, NaiveTime, Utc}; use mininews::parser::{parse, EventBlock, PAGE_URL}; use reqwest::blocking::get; use rss::{ChannelBuilder, Guid, Item, ItemBuilder}; -use uuid::{Timestamp, Uuid}; fn generate_feed(items: &Vec, exclude_today: bool) -> Result { let mut channel = ChannelBuilder::default() @@ -42,13 +41,7 @@ fn generate_feed(items: &Vec, exclude_today: bool) -> Result .pub_date(pub_date.to_rfc2822()) .guid(Guid { permalink: false, - value: Uuid::new_v7(Timestamp::from_unix_time( - pub_date.timestamp() as u64, - 0, - 0, - 0, - )) - .to_string(), + value: pub_date.date_naive().to_string(), }) .description(format!( "Wikipedia current events from {}",