Repository navigation
feat: import events from an .ics calendar file - #18
Merged
Merged
Conversation
Upload an .ics export (Google, Apple, Outlook), review the events, and save them as busy time the planner works around. - Dependency-free parser: line folding, UTC/TZID/floating times, all-day, DURATION, RRULE (validated, date-only UNTIL fixed) and EXDATE - /api/import/calendar parse, save (dedupes by UID) and undo endpoints - /import/calendar page and nav link - Backend and frontend tests Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Upload an
.icsexport (Google, Apple, Outlook), review the events, and save them as busy time that the planner, capacity checks, conflict detection and morning brief already respect.How it works
backend/app/services/ics_import.py, no new dependencies): line folding, UTC / TZID / floating times, all-day events, DURATION, RRULE (validated against the planner's expander; date-onlyUNTILnormalised) and EXDATE. Past, cancelled, invalid and duplicate events are skipped and counted./api/import/calendar):parse(writes nothing),save(one batch, dedupes by calendar UID via the existingevents.external_id),undo./import/calendarpage and a Calendar nav link, with a review step and a 10 second undo.source='ics'.Testing
backend/tests/test_ics_import.py(10 tests, including an HTTP parse, save and undo round trip) andfrontend/tests/ics.test.ts(4 tests).Notes
pyproject.tomlsays Python >=3.9 but the backend needs 3.10+ (X | Noneannotations).🤖 Generated with Claude Code
Summary by cubic
Adds a manual
.icscalendar import (Google, Apple, Outlook) so imported events count as busy time for the planner, capacity checks, conflict detection, and the morning brief./api/import/calendarendpoints:parse(writes nothing),save(one batch, deduped by calendar UID), andundo(available for 10 seconds after saving).DURATION, validatedRRULE(date-onlyUNTILnormalized,EXDATEapplied), and nestedVALARMblocks./import/calendarpage with a review step to uncheck or rename events before saving, plus a Calendar nav link.source='ics'.Written for commit 439b435. Summary will update on new commits.