buzz/ics2owncloud.py

Busy status converted to English

Closed this issue · 1 comments

I exported my outlook calendar (just free/busy status) into ics file. In exported ics file status is in Polish (zajęty for busy). When I import it with your script, the calendar item is stored as busy (translated into English). The same ics file imported via gui gives calendar items in my local language.

Seems to be related with "requests".
I tested with wget.
wget --header='Accept-Language: pl-pl' https://outlook.office365.com/owa/c...
produces Polish summaries, while plain wget gives them in English.
Added headers parameter to fetch and now it is fine:
# fetch webcal
ics_header={'Accept-Language': 'pl-pl'}
c = Calendar.from_ical(requests.get(ics_url,headers=ics_header).text)