Add delete_event functionality with series deletion option and tests#1
Open
iancanderson wants to merge 1 commit intoOmar-V2:mainfrom
Open
Add delete_event functionality with series deletion option and tests#1iancanderson wants to merge 1 commit intoOmar-V2:mainfrom
iancanderson wants to merge 1 commit intoOmar-V2:mainfrom
Conversation
Owner
|
Hey, thank you so much for your contribution, really appreciate it! I've left a couple comments below:
|
tamm
referenced
this pull request
in tamm/mcp-ical
Nov 12, 2025
…tching This PR addresses the issues identified in PR #1 by implementing a more robust solution for deleting recurring event occurrences with proper timezone handling. Key improvements: 1. **Timezone-aware occurrence matching** - New find_event_occurrence() method with exact datetime matching - Automatic UTC fallback for naive datetimes (common in LLM-constructed dates) - Uses ±1 minute search window followed by exact datetime equality check - Prevents wrong occurrence deletion issues from PR #1 2. **Flexible deletion modes** - Delete single occurrence: occurrence_date only (default) - Delete from occurrence forward: occurrence_date + delete_entire_series=True - Delete entire series: delete_entire_series=True only - Delete non-recurring event: event_id only (unchanged behavior) 3. **Comprehensive test coverage** - test_delete_non_recurring_event: Basic deletion case - test_delete_recurring_event_entire_series: Delete all occurrences - test_delete_recurring_event_single_occurrence: Delete one specific occurrence - test_delete_recurring_event_from_occurrence_forward: Delete from occurrence onward - All tests verify expected behavior with occurrence counts 4. **Enhanced MCP tool documentation** - CRITICAL warnings about using exact datetimes from list_events - Clear usage examples for all deletion scenarios - Explanation of timezone importance to prevent user errors Fixes the two main issues from PR #1: - Wrong occurrence being deleted (timezone matching problem) - Events appearing deleted but not actually being removed (matching failure) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This was referenced Nov 12, 2025
bradwindy
pushed a commit
to bradwindy/mcp-ical
that referenced
this pull request
Dec 16, 2025
…on-with-timezone-handling Add robust recurring event deletion with timezone-aware occurrence matching
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.
This pull request introduces the ability to delete either a single occurrence or all future occurrences of a recurring event in the calendar management system. It includes updates to the
delete_eventmethod, a new async function for deleting events, and corresponding tests.