Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump ical and use new RecurrenceIterable for improved debug #156

Merged
merged 1 commit into from
Dec 4, 2022
Merged

Conversation

allenporter
Copy link
Owner

Bump ical and use new RecurrenceIterable for improved debug support. The new iter wraps dateutil.ruleset and contains all the helpers for converting back/forth for all day events since dateutil.rrule only supports datetime.datetime iteration. Additionally, this should help with extra debugging information to diagnose issues like this where the rruleset is comparing dates and times of different types:

  File "/usr/local/lib/python3.10/site-packages/gcal_sync/timeline.py", line 106, in __iter__
    for value in self._func:
  File "/usr/local/lib/python3.10/site-packages/gcal_sync/timeline.py", line 92, in __iter__
    for value in self._dt_iter:
  File "/usr/local/lib/python3.10/site-packages/ical/iter.py", line 113, in __iter__
    for dtvalue in self._recur:
  File "/usr/local/lib/python3.10/site-packages/dateutil/rrule.py", line 1396, in _iter
    heapq.heapify(rlist)
  File "/usr/local/lib/python3.10/site-packages/dateutil/rrule.py", line 1338, in __lt__
    return self.dt < other.dt
TypeError: can't compare datetime.datetime to datetime.date

@allenporter allenporter merged commit 420d761 into main Dec 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant