Skip to content

deletion of task has no effect #83

Closed as not planned
Closed as not planned
@haegar33

Description

@haegar33

Bug description

using the api.delete_task() function reports success but task are still present

Expected behaviour

when executing the api.delete_task() twice I would expect an error for the second call as task should be already deleted

Is reproducible

Yes

To reproduce

Code Snipplet:

from todoist_api_python.api import TodoistAPI
api = TodoistAPI(key)

I receive a list of completed task via the REST API as this does not work with the python module. I get a python dict clist, then:

  for c in clist:
        print('Delete item: ',c['content'],c['task_id'])
        try:
            is_success = api.delete_task(task_id=c['task_id'])
            print(is_success)
        except Exception as error:
            print(error)

works fine, but when I run the script a second time all "deleted" tasks are back again

Version information:

  • Package version: 8.1.3
  • Python version: 3.10

Additional information

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions