Azure-devops-docs: Couldn't run in my pipeline with following error.

Created on 27 Apr 2019  Â·  6Comments  Â·  Source: MicrosoftDocs/azure-devops-docs

Step references task 'Delay' at version '1.1.6' which is not valid for the given job target.


Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

Pri2 devops-cictech devopprod doc-bug

Most helpful comment

@MS please add an understandable error message instead of this obscure one.

All 6 comments

@shahban for Gate/Server phase tasks

Looks like you have a specific task version referred in the yaml.
Can you confirm your yaml looks like the following?

  • job: RunsOnServer
    pool: Server
    steps:

    • task: Delay@1

      inputs:

      delayForMinutes: '1'

Closing the issue due to no response from the customer

In case this helps anyone else - this happens if you try and run the delay task outside of an agentless job. Documentation makes reference to the fact that "Can be used in only an agentless job of a release pipeline."

same problem

error msg

Job Job: Step references task 'Delay' at version '1.1.8' which is not valid for the given job target.

pipeline

'
trigger:

  • master

pool:
vmImage: 'windows-latest'

variables:
solution: '*/.sln'
buildPlatform: 'Any CPU'
buildConfiguration: 'Release'

steps:

  • task: NuGetToolInstaller@1

  • task: DotNetCoreCLI@2
    inputs:
    command: 'publish'
    publishWebProjects: true

  • task: Delay@1
    inputs:
    delayForMinutes: '05'

  • task: CopyFiles@2
    inputs:
    targetFolder: '$(Build.ArtifactStagingDirectory)'

  • task: PublishBuildArtifacts@1
    inputs:
    PathtoPublish: '$(Build.ArtifactStagingDirectory)'
    ArtifactName: 'drop'
    publishLocation: 'Container'

  • task: NuGetCommand@2
    inputs:
    restoreSolution: '$(solution)'

  • task: VSBuild@1
    inputs:
    solution: '$(solution)'
    msbuildArgs: '/p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:SkipInvalidConfigurations=true /p:DesktopBuildPackageLocation="$(build.artifactStagingDirectory)\WebApp.zip" /p:DeployIisAppPath="Default Web Site"'
    platform: '$(buildPlatform)'
    configuration: '$(buildConfiguration)'

  • task: VSTest@2
    inputs:
    platform: '$(buildPlatform)'
    configuration: '$(buildConfiguration)'

`

@MS please add an understandable error message instead of this obscure one.

Was this page helpful?
0 / 5 - 0 ratings