icalendar AssertionError: VTIMEZONEs sub-components' DTSTART must be of type datetime, not date

icalendar AssertionError: VTIMEZONEs sub-components' DTSTART must be of type datetime, not date

当我运行这段代码在Python3.75时,vscode:

from icalendar import Calendar 
import requests
SkeddaBridgeURL = 'https://bridgeartspace.skedda.com/ical?key=457bda7'
f=requests.get(SkeddaBridgeURL)
c = Calendar.from_ical(f.text)

我收到这个错误:

VTIMEZONEs sub-components' DTSTART must be of type datetime, not date
  File "/Users/jeff/Scrape/Code/skedda.py", line 6, in <module>
    c = Calendar.from_ical(f.text)

但是当我 运行 这个 URL 通过 https://icalendar.org/validator.html 的 ical 验证器时,我没有得到任何错误。

我觉得没有资格将此称为错误,但也许是!

我尝试处理这个问题的一种方法是通过启动标志来抑制断言错误,如下所示: python 3 -Oc "Assert False"

但是我没看到如何在 VSCode 中将其设置为标志,我也在学习。

此外,运行通过 pip3 安装 icalendar 后,运行调试器在此代码上运行,我无法进入或修改代码。我是否需要弄清楚如何从 github 下载整个模块并删除断言?

时区夏令时更改从 DATE & TIME 开始,而不仅仅是一天,因此它必须是 DATE-TIME 而不是 DATE。来自 https://icalendar.org/iCalendar-RFC-5545/3-6-5-time-zone-component.html

The mandatory "DTSTART" property gives the effective onset date and local time for the time zone sub-component definition. "DTSTART" in this usage MUST be specified as a date with a local time value.

根据我的经验,各种验证器并没有把所有的东西都捡起来,所以我试着检查我能找到的所有东西。此外,各种主要的日历应用程序并不都支持 RFC5545 规范中的所有内容。 (例如:google calendar didn't do recurring BYHOUR last I checked.)因此最好也对主要的日历应用程序进行测试。 Google 过去对文件非常挑剔,但总是没有好消息。