Radicale icon indicating copy to clipboard operation
Radicale copied to clipboard

Missing dependency: pytz

Open sphh opened this issue 7 years ago • 4 comments

I installed radicale with pip3 install --upgrade radicale. When I run the server, I get this error:

May 02 09:11:33 www python3[12203]: ERROR:root:No module named 'pytz'

After installing pytz with pip3 install pytz, everything works fine.

Please add the pytz package to the dependencies or mention it in the documentation. Thanks.

sphh avatar May 02 '18 11:05 sphh

pytz is an optional dependency of vobject. It shouldn't be required, when your iCalendar files are valid. Can you provide an example file?

Unrud avatar May 04 '18 11:05 Unrud

Here is one of my iCalendar files. It was created by Thunderbird/Lightning:

BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//PYVOBJECT//NONSGML Version 1//EN
BEGIN:VTIMEZONE
TZID:Europe/London
BEGIN:STANDARD
DTSTART:20001029T030000
RRULE:FREQ=YEARLY;BYDAY=-1SU;BYMONTH=10
TZNAME:GMT
TZOFFSETFROM:+0100
TZOFFSETTO:+0000
END:STANDARD
BEGIN:DAYLIGHT
DTSTART:20000326T010000
RRULE:FREQ=YEARLY;BYDAY=-1SU;BYMONTH=3
TZNAME:BST
TZOFFSETFROM:+0000
TZOFFSETTO:+0100
END:DAYLIGHT
END:VTIMEZONE
BEGIN:VEVENT
UID:6b6fbf57-ea05-4717-a62e-24b314bd72af
DTSTART;TZID=Europe/London:20160616T090000
DTEND;TZID=Europe/London:20160616T162000
CATEGORIES:My special category
CREATED:20160413T143427Z
DESCRIPTION:Description
DTSTAMP:20160413T143524Z
LAST-MODIFIED:20160413T143524Z
LOCATION:Secret Location
SUMMARY:STG
TRANSP:OPAQUE
END:VEVENT
END:VCALENDAR

sphh avatar May 09 '18 09:05 sphh

In docker-radicale, @silaslenz reported an issue about timezone being required with recurring events and daylight savings. See https://stackoverflow.com/a/42941087

So I decided to merge his PR that adds pytz as a dependency. pytz should correctly parse timezone and solves the problem.

BTW, pytz seems to be a dependency of radicale package in the Debian repository (it is installed as python3-tz I think).

tomsquest avatar Jun 02 '20 06:06 tomsquest

I also had to install pytz to be able to upload my calendar ICS file within Radicale.

fcorneli avatar Jul 28 '21 06:07 fcorneli

@pbiering Why was this closed?

dotlambda avatar Mar 18 '24 16:03 dotlambda

can't replicate on a system (EL9) having "pytz" not installed.

pbiering avatar Mar 18 '24 19:03 pbiering

Confirmed current vobject can parse the above iCalendar object without pytz installed.

da4089 avatar Mar 19 '24 13:03 da4089