1
votes

In the Visual Studio Marketplace (https://marketplace.visualstudio.com) I found an extension (version 1) that I now use in my Azure Devops build pipeline. I contacted the author who made a small improvement and the new version of the extension was pushed yesterday. In the VS MarketPlace I also see that v2 has become available. However, when I go to my build pipeline I can still only select version 1.

I've contacted my organization's admin to ensure that the latest version is installed. We have even tried to remove the extension for the organization (at which point that was reflected in my build definition) and re-install it, but still I can only select version 1.

Any ideas why I cannot access the latest version of the extension?

2

2 Answers

6
votes

In my case, the problem was not updating the task version in task.json file. Updating the extension's version (in the manifest file) is not enough. If the task version is not changed, Azure DevOps will not update the task itself (despite correctly updating the extension on the "Extensions" page).

1
votes

Did the extension bundle multiple versions of tasks? Generally, we include one version of a task in your extension. Now it is also possible to include multiple versions in one extension, it is helpful if you want to roll out future versions of your extension without interrupting service of users running older versions. You can see the multiple version layout. You can only select version 1, that means the extension include only one version task, even you updated the version number in the task schema. In other word, the version you can select is not the version of the task itself, it means in this extension includes how many different version task.

Please see following example extension manifest which includes multiple version task.

{
    "manifestVersion": 1,
    "id": "build-release-extension-task",
    "name": "Build and Release Extension Tools",
    "version": "0.1.0",
    "publisher": "{your publisher id}",
    "targets": [
        {
            "id": "Microsoft.VisualStudio.Services"
        }
    ],    
    "description": "Tools for building/releasing with Fabrikam. Includes one build/release task.",
    "categories": [
        "Azure Pipelines"
    ],
    "icons": {
        "default": "images/ic_extension.png"        
    },
    "files": [
        {
            "path": "buildAndReleaseExtensionTaskV1"
        },
        {
    "path": "buildAndReleaseExtensionTaskV2"
        }       
    ],
    "contributions": [
        {
            "id": "custom-build-release-task-v1",
            "type": "ms.vss-distributed-task.task",
            "targets": [
                "ms.vss-distributed-task.tasks"
            ],
            "properties": {
                "name": "buildAndReleaseExtensionTaskV1"
            }
        },
        {
            "id": "custom-build-release-task-v2",
            "type": "ms.vss-distributed-task.task",
            "targets": [
                "ms.vss-distributed-task.tasks"
            ],
            "properties": {
                "name": "buildAndReleaseExtensionTaskV2"
            }
        }       
    ]
}

enter image description here