Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-30450

Creating label no longer support build parameters

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • tfs-plugin
    • Jenkins ver. 1.617
      Windows 2008 64bit
      TFS plug-in 4.0.0

      Before upgrading to 4.0.0 I was using this plugin to get the code/apply a label to a branch based on the job parameter, so in my setup I have:

      Server = http://myserver:8080/tfs/TFS2010
      Project Path = $/${Branch}/DMSP/Request Administration

      Where ${Branch} is the branch name, populated from a "Choice Parameter". After I installed the new version, I noticed that applying label is no longer working, my label name is:

      "RequestAdministration-${AppVersion}"

      But once the job runs its trying to apply the label to ${Branch} and not to the real branch name:

      Creating label 'RequestAdministration-4.2.0.7' on '$/${Branch}/DMSP/Request Administration' as of the current version in workspace 'Hudson-RequestAdministration-MASTER'...
      ERROR: Build step failed with exception
      java.lang.RuntimeException: com.microsoft.tfs.core.exceptions.TECoreException: TF10122: The path '$/${Branch}/DMSP/Request Administration' contains a '$' at the beginning of a path component. Remove the '$' and try again.
      at hudson.plugins.tfs.model.Server.execute(Server.java:110)

      On the version 3.2 its works great:
      [RequestAdministration] $ "C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\tf.exe" label RequestAdministration-4.2.0.8 . -version:WHudson-RequestAdministration-MASTER -comment:Automatically_applied_by_Jenkins_TFS_plugin -noprompt -recursive -server:http://myserver:8080/tfs/TFS2010 ********

      Thanks!

      Full error is below:
      Creating label 'RequestAdministration-4.2.0.7' on '$/${Branch}/DMSP/Request Administration' as of the current version in workspace 'Hudson-RequestAdministration-MASTER'...
      ERROR: Build step failed with exception
      java.lang.RuntimeException: com.microsoft.tfs.core.exceptions.TECoreException: TF10122: The path '$/${Branch}/DMSP/Request Administration' contains a '$' at the beginning of a path component. Remove the '$' and try again.
      at hudson.plugins.tfs.model.Server.execute(Server.java:110)
      at hudson.plugins.tfs.TFSLabeler.perform(TFSLabeler.java:85)
      at hudson.tasks.BuildStepMonitor$2.perform(BuildStepMonitor.java:32)
      at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779)
      at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:726)
      at hudson.model.Build$BuildExecution.post2(Build.java:185)
      at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:671)
      at hudson.model.Run.execute(Run.java:1769)
      at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      at hudson.model.ResourceController.execute(ResourceController.java:98)
      at hudson.model.Executor.run(Executor.java:374)
      Caused by: com.microsoft.tfs.core.exceptions.TECoreException: TF10122: The path '$/${Branch}/DMSP/Request Administration' contains a '$' at the beginning of a path component. Remove the '$' and try again.
      at com.microsoft.tfs.core.exceptions.mappers.TECoreExceptionMapper.map(TECoreExceptionMapper.java:105)
      at com.microsoft.tfs.core.exceptions.mappers.VersionControlExceptionMapper.map(VersionControlExceptionMapper.java:50)
      at com.microsoft.tfs.core.clients.versioncontrol.internal.WebServiceLayer.labelItem(WebServiceLayer.java:1282)
      at com.microsoft.tfs.core.clients.versioncontrol.internal.WebServiceLayerLocalWorkspaces.labelItem(WebServiceLayerLocalWorkspaces.java:909)
      at com.microsoft.tfs.core.clients.versioncontrol.VersionControlClient.createLabel(VersionControlClient.java:5057)
      at hudson.plugins.tfs.model.MockableVersionControlClient.createLabel(MockableVersionControlClient.java:48)
      at hudson.plugins.tfs.commands.LabelCommand.call(LabelCommand.java:67)
      at hudson.plugins.tfs.commands.LabelCommand.call(LabelCommand.java:22)
      at hudson.remoting.LocalChannel.call(LocalChannel.java:45)
      at hudson.plugins.tfs.model.Server.execute(Server.java:106)
      ... 10 more
      Caused by: com.microsoft.tfs.core.ws.runtime.exceptions.SOAPFault: TF10122: The path '$/${Branch}/DMSP/Request Administration' contains a '$' at the beginning of a path component. Remove the '$' and try again.
      at com.microsoft.tfs.core.ws.runtime.client.SOAP12Service.examineResponseDOMForFault(SOAP12Service.java:132)
      at com.microsoft.tfs.core.ws.runtime.client.SOAPService.examineBodyForFault(SOAPService.java:1103)
      at com.microsoft.tfs.core.ws.runtime.client.SOAPService.executeSOAPRequestInternal(SOAPService.java:732)
      at com.microsoft.tfs.core.ws.runtime.client.SOAPService.executeSOAPRequest(SOAPService.java:475)
      at ms.tfs.versioncontrol.clientservices._03._RepositorySoap12Service.labelItem(_RepositorySoap12Service.java:889)
      at com.microsoft.tfs.core.clients.versioncontrol.internal.WebServiceLayer.labelItem(WebServiceLayer.java:1267)
      ... 17 more
      Build step 'Create a label in TFS' marked build as failure

            Unassigned Unassigned
            guilherme_labigalini guilherme labigalini
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: