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

"Unable to find project" in "Permission to Copy Artifact - Projects to allow copy artifacts" with multi-configuration projects

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • copyartifact-plugin
    • None
    • Ubuntu 14.04 x86_64
      Oracle JDK 1.7
      Jenkins ver. 1.642.1
      Copy Artifact Plugin ver 1.37
      CloudBees Folders Plugin ver 5.1

      Related to: JENKINS-14999

      To use input parameter variable in "project name" of "copy artifacts from another project",
      you must set proper read permission at upstream job.

      At upstream job while working together with CloudBees Folders Plugin,
      "Permission to Copy Artifact - Projects to allow copy artifacts"
      display a misleading warning "Unable to find project: DOWNSTREAM_PROJECT_NAME"
      when using DOWNSTREAM_PROJECT_NAME only without "FOLDERNAME" prefix.

      When using full complete name together with FOLDER_NAME,
      such as "FOLDERNAME/DOWNSTREAM_PROJECT_NAME",
      "Permission to Copy Artifact - Projects to allow copy artifacts" will not display warning.
      However,
      the downstream job is unable to copy artifacts with error:

      ERROR: Unable to find project for artifact copy: FOLDER_NAME/DOWNSTREAM_PROJECT_NAME
      This may be due to incorrect project name or permission settings; see help for project name in job configuration.
      

      If it's intended to use PROJECT_NAME only without full-name to include FOLDER_NAME,
      then it should not display this misleading warning.
      Also this note should put together with HELP string.

          [JENKINS-33257] "Unable to find project" in "Permission to Copy Artifact - Projects to allow copy artifacts" with multi-configuration projects

          Rick Liu created issue -
          Rick Liu made changes -
          Description Original: Related to: JENKINS-14999

          To use input parameter variable in "*+project name+*" of "*+copy artifacts from another project+*",
          you must set proper read permission at upstream job.

          At upstream job while working together with *+CloudBees Folders Plugin+*,
          "*+Permission to Copy Artifact - Projects to allow copy artifacts+*"
          display a misleading warning "{color:red}*+Unable to find project: DOWNSTREAM_PROJECT_NAME+*{color}"
          when using DOWNSTREAM_PROJECT_NAME only without "FOLDERNAME" prefix.

          When using full complete name together with FOLDER_NAME,
          such as "*+FOLDERNAME/DOWNSTREAM_PROJECT_NAME+*",
          "*+Permission to Copy Artifact - Projects to allow copy artifacts+*" will not display warning.
          However,
          the downstream job is unable to copy artifacts with error:


          {code:bash}
          ERROR: Unable to find project for artifact copy: FOLDER_NAME/DOWNSTREAM_PROJECT_NAME
          This may be due to incorrect project name or permission settings; see help for project name in job configuration.
          {code}




          New: Related to: JENKINS-14999

          To use input parameter variable in "*+project name+*" of "*+copy artifacts from another project+*",
          you must set proper read permission at upstream job.

          At upstream job while working together with *+CloudBees Folders Plugin+*,
          "*+Permission to Copy Artifact - Projects to allow copy artifacts+*"
          display a misleading warning "{color:red}*+Unable to find project: DOWNSTREAM_PROJECT_NAME+*{color}"
          when using DOWNSTREAM_PROJECT_NAME only without "FOLDERNAME" prefix.

          When using full complete name together with FOLDER_NAME,
          such as "*+FOLDERNAME/DOWNSTREAM_PROJECT_NAME+*",
          "*+Permission to Copy Artifact - Projects to allow copy artifacts+*" will not display warning.
          However,
          the downstream job is unable to copy artifacts with error:


          {code:none}
          ERROR: Unable to find project for artifact copy: FOLDER_NAME/DOWNSTREAM_PROJECT_NAME
          This may be due to incorrect project name or permission settings; see help for project name in job configuration.
          {code}




          Rick Liu made changes -
          Description Original: Related to: JENKINS-14999

          To use input parameter variable in "*+project name+*" of "*+copy artifacts from another project+*",
          you must set proper read permission at upstream job.

          At upstream job while working together with *+CloudBees Folders Plugin+*,
          "*+Permission to Copy Artifact - Projects to allow copy artifacts+*"
          display a misleading warning "{color:red}*+Unable to find project: DOWNSTREAM_PROJECT_NAME+*{color}"
          when using DOWNSTREAM_PROJECT_NAME only without "FOLDERNAME" prefix.

          When using full complete name together with FOLDER_NAME,
          such as "*+FOLDERNAME/DOWNSTREAM_PROJECT_NAME+*",
          "*+Permission to Copy Artifact - Projects to allow copy artifacts+*" will not display warning.
          However,
          the downstream job is unable to copy artifacts with error:


          {code:none}
          ERROR: Unable to find project for artifact copy: FOLDER_NAME/DOWNSTREAM_PROJECT_NAME
          This may be due to incorrect project name or permission settings; see help for project name in job configuration.
          {code}




          New: Related to: JENKINS-14999

          To use input parameter variable in "*+project name+*" of "*+copy artifacts from another project+*",
          you must set proper read permission at upstream job.

          At upstream job while working together with *+CloudBees Folders Plugin+*,
          "*+Permission to Copy Artifact - Projects to allow copy artifacts+*"
          display a misleading warning "{color:red}*+Unable to find project: DOWNSTREAM_PROJECT_NAME+*{color}"
          when using DOWNSTREAM_PROJECT_NAME only without "FOLDERNAME" prefix.

          When using full complete name together with FOLDER_NAME,
          such as "*+FOLDERNAME/DOWNSTREAM_PROJECT_NAME+*",
          "*+Permission to Copy Artifact - Projects to allow copy artifacts+*" will not display warning.
          However,
          the downstream job is unable to copy artifacts with error:


          {code:none}
          ERROR: Unable to find project for artifact copy: FOLDER_NAME/DOWNSTREAM_PROJECT_NAME
          This may be due to incorrect project name or permission settings; see help for project name in job configuration.
          {code}


          If it's intended to use PROJECT_NAME only without full-name to include FOLDER_NAME,
          then it should not display this misleading warning.
          Also this note should put together with HELP string.


          Rick Liu made changes -
          Attachment New: screenshot-1.png [ 32075 ]
          Rick Liu made changes -
          Attachment New: screenshot-2.png [ 32076 ]

          ikedam added a comment -

          It sounds like a bug rather than a misleading behavior. Project names are expected to be treated relatively.
          But I can't reproduce the problem in my environment.
          Would you tell more detailed steps to reproduce the problem?

          Steps I tried (with Jenkins 1.642.1, cloudbees folder 5.1, copysrtifact 1.37)

          1. Lauch a newly installed Jenkins 1.642.1.
          2. Download and install Cloudbees Folder 5.1.
            • It is not the latest and you can't get it from Manage Pkugins.
          3. Go to Manage Jenkins>Manage Pkugins and install Copyartifact 1.37.
          4. Create a folder "FOLDERNAME".
          5. Create a freestyle project "DOWNSTREAM_PROJECT_NAME" in FOLDERNAME.
          6. In the configuration page of DOWNSTREAM_PROJECT_NAME, check "Permission to Copy Artifact"
          7. Put DOWNSTREAM_PROJECT_NAME to "projects to allow copy artifacts"
            • It can be input with the auto-completion.

          Result:

          • No warnings are displayed.

          ikedam added a comment - It sounds like a bug rather than a misleading behavior. Project names are expected to be treated relatively. But I can't reproduce the problem in my environment. Would you tell more detailed steps to reproduce the problem? Steps I tried (with Jenkins 1.642.1, cloudbees folder 5.1, copysrtifact 1.37) Lauch a newly installed Jenkins 1.642.1. Download and install Cloudbees Folder 5.1. It is not the latest and you can't get it from Manage Pkugins. Go to Manage Jenkins>Manage Pkugins and install Copyartifact 1.37. Create a folder "FOLDERNAME". Create a freestyle project "DOWNSTREAM_PROJECT_NAME" in FOLDERNAME. In the configuration page of DOWNSTREAM_PROJECT_NAME, check "Permission to Copy Artifact" Put DOWNSTREAM_PROJECT_NAME to "projects to allow copy artifacts" It can be input with the auto-completion. Result: No warnings are displayed.

          Rick Liu added a comment -

          My downstream job is a freestyle project,
          but my upstream job is a multi-configuration matrix project.

          I'm not sure if that would make any differences.

          From Step 1~4 looks the same as mine,

          4. Create a folder "FOLDER"
          5. Create a freestyle project "DOWNSTREAM_PROJECT" in "FOLDER"
          6. Create a multi-configuration matrix project "UPSTREAM_PROJECT" in "FOLDER"
          7. In the configuration page of "UPSTREAM_PROJECT",
          check "Permission to Copy Artifact"
          8. Put "DOWNSTREAM_PROJECT" to "projects to allow copy artifacts"

          • Mine can't do the auto-completion.

          I'll also attach the list of current installed plugin and versions.

          Rick Liu added a comment - My downstream job is a freestyle project, but my upstream job is a multi-configuration matrix project. I'm not sure if that would make any differences. From Step 1~4 looks the same as mine, 4. Create a folder "FOLDER" 5. Create a freestyle project "DOWNSTREAM_PROJECT" in "FOLDER" 6. Create a multi-configuration matrix project "UPSTREAM_PROJECT" in "FOLDER" 7. In the configuration page of "UPSTREAM_PROJECT", check "Permission to Copy Artifact" 8. Put "DOWNSTREAM_PROJECT" to "projects to allow copy artifacts" Mine can't do the auto-completion. I'll also attach the list of current installed plugin and versions.

          Rick Liu added a comment -

          The list of installed plugins and versions.

          Rick Liu added a comment - The list of installed plugins and versions.
          Rick Liu made changes -

          Rick Liu added a comment -

          Jenkins System Information

          Rick Liu added a comment - Jenkins System Information
          Rick Liu made changes -
          Attachment New: System Information [Jenkins].htm [ 32087 ]

            ikedam ikedam
            totoroliu Rick Liu
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: