I'm trying to use the Jenkins-Reviewbot plugin with Perforce as the SCM.
While I managed to get a trivial patch (with a single added line to a file)
to work, more complex patches fail.
Has anyone managed to get the plugin working with Perforce?
The problem apparently has to do with the patch format as returned by
reviewboard (1.7.6 in my case). The patch has the file names as Perforce
paths, i.e. prefixed with //depot/project/branch. The workaround specified
in JENKINS-20396 should be enough to get this working, but for now I'm
stuck.
The patches fail with messages such as
Caused by: java.lang.IndexOutOfBoundsException: Index: 12, Size: 12
at java.util.ArrayList.rangeCheck(ArrayList.java:604)
at java.util.ArrayList.get(ArrayList.java:382)
at
com.cloudbees.diff.ContextualPatch.applyHunk(ContextualPatch.java:260)
at
com.cloudbees.diff.ContextualPatch.findHunkIndex(ContextualPatch.java:234)
at
com.cloudbees.diff.ContextualPatch.applyHunk(ContextualPatch.java:227)
at
com.cloudbees.diff.ContextualPatch.applyPatch(ContextualPatch.java:155)
at com.cloudbees.diff.ContextualPatch.patch(ContextualPatch.java:108)
at
org.jenkinsci.plugins.jenkinsreviewbot.ReviewboardParameterValue$ApplyTask.invoke(ReviewboardParameterValue.java:225)
and
Caused by: com.cloudbees.diff.PatchException: Cannot apply hunk @@ 71
at
com.cloudbees.diff.ContextualPatch.applyHunk(ContextualPatch.java:228)
at
com.cloudbees.diff.ContextualPatch.applyPatch(ContextualPatch.java:155)
at com.cloudbees.diff.ContextualPatch.patch(ContextualPatch.java:108)
at
org.jenkinsci.plugins.jenkinsreviewbot.ReviewboardParameterValue$ApplyTask.invoke(ReviewboardParameterValue.java:225)
- David
--
You received this message because you are subscribed to the Google Groups
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.