Yes, there problem was wrong id.
I tried search as:
gmp.get_tasks(filter='name=Web test scan')
But, id of task ‘test scan’ returns, not id of moved task ‘Web test scan’
Then I renamed ‘Web test scan’ to ‘Web_test_scan’, and now i try to find moved task to trashcan by this code:
tasks = gmp.get_tasks(filter='name=Web_test_scan')
for task in tasks.xpath('task'):
my_task_id = task.get('id')
print ('---- ' + my_task_id + ' ----')
But it doesn’t find task ‘Web_test_scan’ when it is in the trashcan.
When the task ‘Web_test_scan’ in restored, code above find ID perfectly.
How to find id of deleted task correctly ?