POST /tasks/{id}/move with section_id silently strips parent_id from subtasks
还没有人认领这个 Issue。
评估
调研方向
Locate the implementation and tests for POST /api/v1/tasks/{task_id}/move, then reproduce the section_id path with a parent task and subtask. Compare it with the parent_id path and add coverage showing that moving by section preserves the parent relationship or returns an explicit warning or error.
由索引模型根据 Issue 内容生成。
描述
Description
When moving a subtask to a section via POST /api/v1/tasks/{task_id}/move with {"section_id": "..."}, the API silently clears the task's parent_id, promoting the subtask to a top-level task. The response returns 200 with no warning that the parent relationship was removed.
Steps to reproduce
- Create a parent task and a subtask under it (
parent_idset). - Call
POST /api/v1/tasks/{subtask_id}/movewith body{"section_id": "<section_id>"}. - Fetch the task again:
parent_idis nownull.
Expected behavior
Moving a subtask between sections should preserve its parent_id, or the API should return an error/warning if detaching the parent is intentional.
Actual behavior
The subtask is silently detached and becomes a top-level task in the target section.
Additional context
- Moving with
{"parent_id": "<parent_id>"}on the same endpoint does re-attach the task, so the move endpoint clearly understands parentage. Only thesection_idvariant drops it. - The task update endpoint (
POST /api/v1/tasks/{task_id}) rejectsparent_idas an unsupported field, so the move endpoint is currently the only way to restore the relationship after it is lost. - Observed against REST API v1 on 2026-09-22.
- 主要语言
- Python
- 星标
- 250
- 派生
- 34
- 平均合并
- 2 天 1 小时
- 30 天内合并 PR
- 2
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
Doist/todoist-api-python 的其他 Issue
-
api enhancement
难度 4/5 3-5 天 新手友好度 35/100
Doist/todoist-api-python#219 · 1 条评论 ·
-
api enhancement
难度 3/5 1-2 天 新手友好度 35/100
Doist/todoist-api-python#206 · 1 条评论 ·
-
api enhancement
难度 4/5 3-5 天 新手友好度 45/100
Doist/todoist-api-python#205 · 6 条评论 · 1 个 reaction ·
-
enhancement
难度 5/5 一周以上 新手友好度 35/100
Doist/todoist-api-python#202 ·
-
bug
难度 3/5 1-2 天 新手友好度 35/100
Doist/todoist-api-python#193 · 4 条评论 ·
查看 Doist/todoist-api-python 的全部 Issue
相似的 Issue
-
area:space-accuracy good first issue track:data
难度 2/5 1-3 小时 新手友好度 85/100
Sara-Managed-Projects/space-radar#904 ·
维护者通常 1 天内回复