microsoft / tfs-cli

Cross-platform CLI for Microsoft Team Foundation Server and Visual Studio Team Services
MIT License
370 stars 131 forks source link

tfx build tasks delete doesn't delete task #240

Open karpis opened 6 years ago

karpis commented 6 years ago

tfx-cli version 0.4.11 TFS version 15.117.27024.0

Trying to delete a task I uploaded some time ago that was never used. Here's the output:

PS C:\Users\xxx> tfx build tasks delete --task-id b2fb45ad-3ce6-4d88-a301-2e4cf390ee25
2017-11-23T09:32:07.161Z : loader.load
TFS Cross Platform Command Line Interface v0.4.11
Copyright Microsoft Corporation
2017-11-23T09:32:07.426Z : cache.getItem
2017-11-23T09:32:07.426Z : cache.getItem
2017-11-23T09:32:07.504Z : Deleting task(s)...

Task b2fb45ad-3ce6-4d88-a301-2e4cf390ee25 deleted successfully!

The problem is that the task isn't deleted. It's still available for use in builds and it still shows up if I run tfx build tasks list. I can also run the tfx build tasks delete... command multiple times, and it always produces the Task xxx deleted successfully! output.

jheaddings commented 5 years ago

This is happening to me as well. It was uploaded as part of an extension, so I'm guessing you have to delete the extension and republish it?

pabrams commented 5 years ago

@jheaddings Deleting the extension and re-publishing results in failure on install, because TFS says the task with that ID already exists. Trying to remove the task using tfx build tasks delete fails because it says the build task with that ID already exists.