[JIRA] (JENKINS-37677) Handle jobs in Multibranch projects where git branches have special characters

0 views
Skip to first unread message

andersems@gmail.com (JIRA)

unread,
Aug 25, 2016, 5:35:01 AM8/25/16
to jenkinsc...@googlegroups.com
Anders Emil Salvesen created an issue
 
Jenkins / Bug JENKINS-37677
Handle jobs in Multibranch projects where git branches have special characters
Issue Type: Bug Bug
Assignee: Matthew DeTullio
Components: multi-branch-project-plugin
Created: 2016/Aug/25 9:34 AM
Priority: Major Major
Reporter: Anders Emil Salvesen

I'm using 2.19, with pipeline-plugin 2.2.

I have a git repo with a java and maven project in it. This project has some tests that use the following code to read a file:

new File(this.getClass().getResource("/myfolder/" + filename).getPath())

For that repo, I have a multibranch-project where I have a branch named feature/hahahah. I use a Jenkinsfile in the repo to build from.

When a job is created for this branch, the build fails with the following error:

java.lang.RuntimeException: java.io.FileNotFoundException: /u01/jenkins/workspace/myproject-multibranch/feature%252Fhahahah/prognose/target/test-classes/myfolder/testfile.xml (No such file or directory)
	at ske.fastsetting.skatt.prognose.fra.fil.PrognoseFraFilTest.lesFil(PrognoseFraFilTest.java:172)
	at ske.fastsetting.skatt.prognose.fra.fil.PrognoseFraFilTest.skalleseGrunnlagFraFilOgPrognostisere(PrognoseFraFilTest.java:122)

Is there a way to create the workspace in a folder without %252F?

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)
Atlassian logo

andersems@gmail.com (JIRA)

unread,
Aug 25, 2016, 9:21:02 AM8/25/16
to jenkinsc...@googlegroups.com
Anders Emil Salvesen updated an issue
I'm using 2.19, with pipeline-plugin 2.2.

I have a git repo with a java and maven project in it. This project has some tests that use the following code to read a file:

{code}

new File(this.getClass().getResource("/myfolder/" + filename).getPath())
{code}

For that repo, I have a multibranch-project where I have a branch named feature/hahahah
, with a slash in it . I use a Jenkinsfile in the repo to build from.


When a job is created for this branch, the build fails with the following error:

{code}

java.lang.RuntimeException: java.io.FileNotFoundException: /u01/jenkins/workspace/myproject-multibranch/feature%252Fhahahah/prognose/target/test-classes/myfolder/testfile.xml (No such file or directory)
at ske.fastsetting.skatt.prognose.fra.fil.PrognoseFraFilTest.lesFil(PrognoseFraFilTest.java:172)
at ske.fastsetting.skatt.prognose.fra.fil.PrognoseFraFilTest.skalleseGrunnlagFraFilOgPrognostisere(PrognoseFraFilTest.java:122)
{code}


Is there a way to create the workspace in a folder without %252F?



mjdetullio@gmail.com (JIRA)

unread,
Aug 31, 2016, 3:41:03 PM8/31/16
to jenkinsc...@googlegroups.com
Reply all
Reply to author
Forward
0 new messages