e
This commit is contained in:
parent
00000d98b2
commit
00000d9449
5 changed files with 17 additions and 18 deletions
|
|
@ -213,11 +213,11 @@ async def get_events(
|
|||
) -> list[dict[str, str]]:
|
||||
|
||||
events: list[dict[str, str]] = []
|
||||
pub_date_format = "%a, %d %b %Y %H:%M:%S %z"
|
||||
|
||||
window_start, window_end = now - timedelta(hours=1), now + timedelta(minutes=30)
|
||||
|
||||
if buffer := await fetch_xml_stream(url, ssl_ctx):
|
||||
pub_date_format = "%a, %d %b %Y %H:%M:%S %z"
|
||||
|
||||
for _, elem in ET.iterparse(buffer, events=("end",)):
|
||||
if elem.tag == "item":
|
||||
title = elem.findtext("title")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue