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

Perforce plugin does not sync paths with space in them, removing these lines from the generated view

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Component/s: perforce-plugin
    • Labels:
      None
    • Environment:
      Windows 7

      Description

      Perforce plugin will not sync paths with space in their names.

      Example:
      //aaa/bbb/... "//hudson_JOB_NAME/aaa/bbb ccc/..."

      This will give an error in the config UI but even if you save it it will fail to sync.

      I checked and in the final workspace(clientspec) this line will be missing and as a side effect the workspace will miss some files.

      This is a major issue considering that there is no workaround for it, making the plugin useless if you are unlucky to have to use spaces in directory names.

        Activity

        Hide
        rpetti Rob Petti added a comment -

        Please provide your hudson version, and perforce plugin version.

        Show
        rpetti Rob Petti added a comment - Please provide your hudson version, and perforce plugin version.
        Hide
        rpetti Rob Petti added a comment -

        BTW, the workaround is to also quote the depot path:

        "//aaa/bbb/..." "//hudson_JOB_NAME/aaa/bbb ccc/..."

        I'll get this fixed for the next release.

        Show
        rpetti Rob Petti added a comment - BTW, the workaround is to also quote the depot path: "//aaa/bbb/..." "//hudson_JOB_NAME/aaa/bbb ccc/..." I'll get this fixed for the next release.
        Hide
        ssbarnea Sorin Sbarnea added a comment -

        Thanks, this is great! Check if it works in all cases:
        {{
        x y
        "x" y
        "x" "y"
        x "y"
        }}

        I suppose there no need for hudson and perforce plugin versions now.

        Show
        ssbarnea Sorin Sbarnea added a comment - Thanks, this is great! Check if it works in all cases: {{ x y "x" y "x" "y" x "y" }} I suppose there no need for hudson and perforce plugin versions now.
        Hide
        rpetti Rob Petti added a comment -

        x y
        "x" y
        "x" "y"

        Should all work already, there just wasn't a valid regex for (x "y").

        Show
        rpetti Rob Petti added a comment - x y "x" y "x" "y" Should all work already, there just wasn't a valid regex for (x "y").
        Hide
        scm_issue_link SCM/JIRA link daemon added a comment -

        Code changed in hudson
        User: : rpetti
        Path:
        trunk/hudson/plugins/perforce/src/main/java/hudson/plugins/perforce/PerforceSCM.java
        http://jenkins-ci.org/commit/35096
        Log:
        [FIXED JENKINS-7496] adding support for client mapping case where there are quotes only around the workspace path, and not the depot path

        Show
        scm_issue_link SCM/JIRA link daemon added a comment - Code changed in hudson User: : rpetti Path: trunk/hudson/plugins/perforce/src/main/java/hudson/plugins/perforce/PerforceSCM.java http://jenkins-ci.org/commit/35096 Log: [FIXED JENKINS-7496] adding support for client mapping case where there are quotes only around the workspace path, and not the depot path
        Hide
        skancharla Srini Kancharla added a comment -

        This bug still exists in the p4 plugin version 1.3.13.
        I have path mapping similiar to
        "//depot/Projects/My Project/..." //proj_deploy_jenkins/...

        and I get an error
        Warning: Client Spec line invalid, ignoring. ("//depot/Projects/My Project/..." //proj_deploy_jenkins/...

        I will try and fix this issue if noone wants to pick this up.

        Show
        skancharla Srini Kancharla added a comment - This bug still exists in the p4 plugin version 1.3.13. I have path mapping similiar to "//depot/Projects/My Project/..." //proj_deploy_jenkins/... and I get an error Warning: Client Spec line invalid, ignoring. ("//depot/Projects/My Project/..." //proj_deploy_jenkins/... I will try and fix this issue if noone wants to pick this up.
        Hide
        rpetti Rob Petti added a comment -

        Srini, quote both parts:
        "//depot/Projects/My Project/..." "//proj_deploy_jenkins/..."

        I'll fix this issue for the next release.

        Show
        rpetti Rob Petti added a comment - Srini, quote both parts: "//depot/Projects/My Project/..." "//proj_deploy_jenkins/..." I'll fix this issue for the next release.
        Hide
        scm_issue_link SCM/JIRA link daemon added a comment -

        Code changed in jenkins
        User: Rob Petti
        Path:
        src/main/java/hudson/plugins/perforce/PerforceSCM.java
        src/test/java/hudson/plugins/perforce/PerforceSCMTest.java
        http://jenkins-ci.org/commit/perforce-plugin/d5ba5f9e1cae2ea613f2ddfc3714067c91789698
        Log:
        [FIXED JENKINS-7496] fix quoting issue in view parsing

        Show
        scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Rob Petti Path: src/main/java/hudson/plugins/perforce/PerforceSCM.java src/test/java/hudson/plugins/perforce/PerforceSCMTest.java http://jenkins-ci.org/commit/perforce-plugin/d5ba5f9e1cae2ea613f2ddfc3714067c91789698 Log: [FIXED JENKINS-7496] fix quoting issue in view parsing
        Hide
        dogfood dogfood added a comment -

        Integrated in plugins_perforce #223
        [FIXED JENKINS-7496] fix quoting issue in view parsing (Revision d5ba5f9e1cae2ea613f2ddfc3714067c91789698)

        Result = SUCCESS
        Rob Petti :
        Files :

        • src/test/java/hudson/plugins/perforce/PerforceSCMTest.java
        • src/main/java/hudson/plugins/perforce/PerforceSCM.java
        Show
        dogfood dogfood added a comment - Integrated in plugins_perforce #223 [FIXED JENKINS-7496] fix quoting issue in view parsing (Revision d5ba5f9e1cae2ea613f2ddfc3714067c91789698) Result = SUCCESS Rob Petti : Files : src/test/java/hudson/plugins/perforce/PerforceSCMTest.java src/main/java/hudson/plugins/perforce/PerforceSCM.java

          People

          • Assignee:
            rpetti Rob Petti
            Reporter:
            ssbarnea Sorin Sbarnea
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: