Fix filter_tasks to include inbox tasks in results#44
Open
sanjeed5 wants to merge 16 commits into
Open
Conversation
…ckTick MCP server Co-authored-by: msanjeed5 <msanjeed5@gmail.com>
…tocol-and-document-1314 Add Codebase-explained.md
…or TickTick tasks
…hentication, task and project management endpoints, and usage examples.
- Consolidated 8 filtering tools into 1 flexible filter_tasks tool - Removed batch_create_tasks (LLM can call create_task multiple times) - Converted GTD tools to prompts (/engaged, /next_actions) - Enhanced all tool descriptions with examples and detailed docs - Fixed critical date parsing bug in filter_tasks and helper functions - Added _parse_ticktick_date() to handle TickTick API date format - Fixed all date-based filters that were silently failing - Updated README.md with new structure and examples Result: 45% reduction in tool count (22 → 12 tools + 2 prompts)
- Add _to_local_date() helper function to convert datetime with timezone to local date - Update _is_task_due_today() to use local timezone - Update _is_task_overdue() to use local timezone with proper naive datetime handling - Update _is_task_due_in_days() to use local timezone - Update filter_tasks() 'this_week' filter to use local timezone - All date comparisons now work according to user's local timezone
- Change now_local from naive datetime to timezone-aware datetime - Use datetime.now(timezone.utc).astimezone() instead of datetime.now() - Fixes comparison error when comparing timezone-aware task_dt_local with naive now_local
Add .mcp.json for project-scoped MCP server config, enabling Claude Code CLI to auto-detect the TickTick MCP server.
The inbox has a special ID format (e.g., "inbox116792701") and may not be returned by get_projects() or handled correctly when iterating through projects. This fix: - Adds logic to detect if inbox is in the projects list - Explicitly adds inbox for fetching if not present when filtering all projects - Handles the special case when project_id="inbox" is specified - Uses actual project info from API response instead of synthetic entry - Gracefully handles errors when fetching project data Fixes #3
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.
Summary
filter_tasksdid not include inbox tasks when filtering across all projectsinbox116792701) and wasn't being returned byget_projects()or handled correctly when iterating through projectsChanges
_get_project_tasks_by_filterto detect if inbox is already in the projects listfilter_tasksto handleproject_id="inbox"directly without searching the projects listTest plan
get_project_tasks("inbox")works (18 tasks found)filter_tasks(date_filter="today")now includes inbox (15 projects = 14 + inbox)filter_tasks(project_id="inbox", date_filter="today")works correctly (4 tasks)