[JIRA] [subversion-plugin] (JENKINS-26318) Subversion Plug in 2.5 causes sporadic problems

13 views
Skip to first unread message

eduardo.raf@gmail.com (JIRA)

unread,
Jun 11, 2015, 7:37:01 AM6/11/15
to jenkinsc...@googlegroups.com
Eduardo Marques commented on Bug JENKINS-26318
 
Re: Subversion Plug in 2.5 causes sporadic problems

Isn't this one a duplicate issue of https://issues.jenkins-ci.org/browse/JENKINS-27079 which has been solved?

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265)
Atlassian logo

jspiker6@gmail.com (JIRA)

unread,
Jun 11, 2015, 9:29:01 AM6/11/15
to jenkinsc...@googlegroups.com

All of these SVN error tickets are marked as resolved but the issue still persists for me.

d.borgards@hawe.de (JIRA)

unread,
Jun 11, 2015, 9:35:02 AM6/11/15
to jenkinsc...@googlegroups.com

We also have these problems if we update - so our solution was inbetween not to update
Please fix! Thankx

dbeck@cloudbees.com (JIRA)

unread,
Jun 11, 2015, 9:39:04 AM6/11/15
to jenkinsc...@googlegroups.com

All of these SVN error tickets are marked as resolved but the issue still persists for me.

The resolution specified is Duplicate, which means there's already a report for it. Doesn't mean the problem was fixed.

d.borgards@hawe.de (JIRA)

unread,
Jun 11, 2015, 9:49:01 AM6/11/15
to jenkinsc...@googlegroups.com

> The resolution specified is Duplicate, which means there's already a report for it. Doesn't mean the problem was fixed.
https://issues.jenkins-ci.org/browse/JENKINS-27079 is marked as resolved, but it isn't...

dbeck@cloudbees.com (JIRA)

unread,
Jun 11, 2015, 10:11:01 AM6/11/15
to jenkinsc...@googlegroups.com

https://issues.jenkins-ci.org/browse/JENKINS-27079 is marked as resolved, but it isn't...

Again, it's resolved as Duplicate. That's just how it looks in Jira.

JENKINS-27079 duplicates JENKINS-26734 , which in turn duplicates JENKINS-26303 . And in the issue comments there, Craig Rodrigues wrote:

I released version 0.4 of the Multiple SCMs plugin, so you can give that a try and report back here if it fixes your problem.

So I'm fairly sure that is the correct place to report any issues.

ssmall@rez1.com (JIRA)

unread,
Jul 8, 2015, 2:27:03 PM7/8/15
to jenkinsc...@googlegroups.com

I'm experiencing this bug on almost every other build of seemingly un-related jobs. I followed the workaround suggested by Łukasz Koniecki to adjust my working copy format to 1.8 and recreate the workspace, but this doesn't seem to work for every job.

I'm running Jenkins 1.617, subversion-plugin version 2.5:

{{FATAL: hudson.scm.SVNRevisionState cannot be cast to hudson.scm.SVNRevisionState
java.lang.ClassCastException: hudson.scm.SVNRevisionState cannot be cast to hudson.scm.SVNRevisionState
at hudson.scm.SubversionSCM.calcChangeLog(SubversionSCM.java:725)
at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:860)
at hudson.scm.SCM.checkout(SCM.java:485)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1282)
at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610)
at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532)
at hudson.model.Run.execute(Run.java:1744)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:98)
at hudson.model.Executor.run(Executor.java:374)}}

It's a big problem for my current configuration, I'm close to attempting a downgrade to 2.4.5 of the subversion-plugin. Please let me know if there's any more information I can provide for this issue.

ssmall@rez1.com (JIRA)

unread,
Jul 8, 2015, 2:27:05 PM7/8/15
to jenkinsc...@googlegroups.com
Steve Small edited a comment on Bug JENKINS-26318

ssmall@rez1.com (JIRA)

unread,
Jul 8, 2015, 2:27:07 PM7/8/15
to jenkinsc...@googlegroups.com

ssmall@rez1.com (JIRA)

unread,
Jul 8, 2015, 2:28:02 PM7/8/15
to jenkinsc...@googlegroups.com
Steve Small edited a comment on Bug JENKINS-26318
I'm experiencing this bug on almost every other build of seemingly un-related jobs.  I followed the workaround suggested by Łukasz Koniecki to adjust my working copy format to 1.8 and recreate the workspace, but this doesn't seem to work for every job.

I'm running Jenkins 1.617, subversion-plugin version 2.5:


{ { code}
FATAL: hudson.scm.SVNRevisionState cannot be cast to hudson.scm.SVNRevisionState
java.lang.ClassCastException: hudson.scm.SVNRevisionState cannot be cast to hudson.scm.SVNRevisionState
at hudson.scm.SubversionSCM.calcChangeLog(SubversionSCM.java:725)
at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:860)
at hudson.scm.SCM.checkout(SCM.java:485)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1282)
at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610)
at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532)
at hudson.model.Run.execute(Run.java:1744)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:98)
at hudson.model.Executor.run(Executor.java:374)

{code
} }


It's a big problem for my current configuration, I'm close to attempting a downgrade to 2.4.5 of the subversion-plugin.  Please let me know if there's any more information I can provide for this issue.

jose.arevalo@mizuhocbus.com (JIRA)

unread,
Jul 23, 2015, 8:12:02 AM7/23/15
to jenkinsc...@googlegroups.com

Yes it would be great if this issue get fixed. This issue is affecting automation. Please give better priority to fix this issue


FATAL: hudson.scm.SVNRevisionState cannot be cast to hudson.scm.SVNRevisionState
java.lang.ClassCastException: hudson.scm.SVNRevisionState cannot be cast to hudson.scm.SVNRevisionState
at hudson.scm.SubversionSCM.calcChangeLog(SubversionSCM.java:725)
at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:860)
at hudson.scm.SCM.checkout(SCM.java:485)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1282)
at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610)
at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532)
at hudson.model.Run.execute(Run.java:1744)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:98)
at hudson.model.Executor.run(Executor.java:374)

daniel.isenmann@googlemail.com (JIRA)

unread,
Jul 24, 2015, 2:29:02 AM7/24/15
to jenkinsc...@googlegroups.com

We have the same issue. No MultipleSCM plugin installed and every single svn checkout failed with the reported error message. Sadly we have to use the new plugin because of the new SVN format of Subversin 1.8.

Please fix this.About 130 Jobs are failing because of this permanently. No workaround from above is working.

christopher.biel89@gmail.com (JIRA)

unread,
Aug 3, 2015, 4:08:07 AM8/3/15
to jenkinsc...@googlegroups.com

slawomir@ezono.com (JIRA)

unread,
Aug 17, 2015, 11:03:03 AM8/17/15
to jenkinsc...@googlegroups.com
Slawomir Czarko commented on Bug JENKINS-26318
 
Re: Subversion Plug in 2.5 causes sporadic problems

This can be caused by duplicate class name (hudson.scm.SVNRevisionState) between subversion-plugin and other plugins, for example BlameSubversion-plugin.

dbeck@cloudbees.com (JIRA)

unread,
Aug 17, 2015, 11:11:03 AM8/17/15
to jenkinsc...@googlegroups.com

True, it looks like BlameSubversion actually has another class of the same name. Clearly a terrible idea.

https://github.com/jenkinsci/BlameSubversion-plugin/blob/master/src/main/java/hudson/scm/SVNRevisionState.java

slawomir@ezono.com (JIRA)

unread,
Aug 18, 2015, 5:39:02 AM8/18/15
to jenkinsc...@googlegroups.com

hudson.scm.SVNRevisionState in subversion-plugin used to be a private class but that was changed in this commit:

commit 75080db63a30d42ac66d5ff46f8fbf49bab6b637
Author: Nicolas De loof <nicolas...@gmail.com>
Date: Thu Oct 30 09:41:43 2014 +0100

Make SVNRevisionState public

Required so another plugin can retrieve the built revision. Typical use case is svnmerge-plugin which has to merge built revision to upstream branch

jose.arevalo@mizuhocbus.com (JIRA)

unread,
Sep 23, 2015, 8:50:04 AM9/23/15
to jenkinsc...@googlegroups.com

I updated to the latest version and the issue is still there

At revision 3327


FATAL: hudson.scm.SVNRevisionState cannot be cast to hudson.scm.SVNRevisionState
java.lang.ClassCastException: hudson.scm.SVNRevisionState cannot be cast to hudson.scm.SVNRevisionState

at hudson.scm.SubversionSCM.calcChangeLog(SubversionSCM.java:726)
at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:861)
at hudson.scm.SCM.checkout(SCM.java:485)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1277)


at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610)
at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532)

at hudson.model.Run.execute(Run.java:1741)


at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:98)

at hudson.model.Executor.run(Executor.java:408)
Finished: FAILURE

dbeck@cloudbees.com (JIRA)

unread,
Sep 23, 2015, 11:43:02 AM9/23/15
to jenkinsc...@googlegroups.com

Anyone here NOT using BlameSubversion plugin?

dbeck@cloudbees.com (JIRA)

unread,
Sep 28, 2015, 9:30:03 PM9/28/15
to jenkinsc...@googlegroups.com
Daniel Beck updated an issue
 
Change By: Daniel Beck
Component/s: blamesubversion-plugin
Component/s: subversion-plugin

dbeck@cloudbees.com (JIRA)

unread,
Sep 28, 2015, 9:30:05 PM9/28/15
to jenkinsc...@googlegroups.com
 
Re: Subversion Plug in 2.5 causes sporadic problems

Assigning to BlameSubversion plugin after no response to previous comment.

jose.arevalo@mizuhocbus.com (JIRA)

unread,
Oct 22, 2015, 9:19:10 AM10/22/15
to jenkinsc...@googlegroups.com

This is not related to BlameSubversion plugin.

joerg.schlenker@star-group.net (JIRA)

unread,
Oct 22, 2015, 9:22:04 AM10/22/15
to jenkinsc...@googlegroups.com

Since i deactivated the BlameSubversion plugin, no more errors occured. So for me it seems its related to it.

dbeck@cloudbees.com (JIRA)

unread,
Oct 22, 2015, 9:48:02 AM10/22/15
to jenkinsc...@googlegroups.com

Jose Arevalo What makes you think this is unrelated to BlameSubversion?

jose.arevalo@mizuhocbus.com (JIRA)

unread,
Oct 23, 2015, 10:58:03 AM10/23/15
to jenkinsc...@googlegroups.com

we removed the BlameSubversion plugin and we still see the same error.

slawomir@ezono.com (JIRA)

unread,
Oct 23, 2015, 11:07:02 AM10/23/15
to jenkinsc...@googlegroups.com

Maybe some other plugin contains conflicting SVNRevisionState class?

On Linux you can run this to check if you have such a plugin (assuming Jenkins is in /var/lib/jenkins/):
for i in $(find /var/lib/jenkins/plugins/ -name '*.jar') ; do ( unzip -l $i | grep -q SVNRevisionState ) && echo $i ; done

alexander.veit@gmx.net (JIRA)

unread,
Oct 23, 2015, 8:01:04 PM10/23/15
to jenkinsc...@googlegroups.com

Why do you think this issue has anything to do with the BlameSubversion plugin? If GitHub is right, the BlameSubversion project has no changes for 3 years. BlameSubversion also does not seem to do any custom class loading.

For


hudson.scm.SVNRevisionState cannot be cast to hudson.scm.SVNRevisionState

to occur, it is not necessary that there are two different class files with name hudson.scm.SVNRevisionState. It suffices that the same class is being loaded from the same file by two different class loaders.

So the cause of the error might also be in the Subversion plugin or in Jenkins itself.

dbeck@cloudbees.com (JIRA)

unread,
Oct 24, 2015, 3:50:04 AM10/24/15
to jenkinsc...@googlegroups.com

Why do you think this issue has anything to do with the BlameSubversion plugin? If GitHub is right, the BlameSubversion project has no changes for 3 years. BlameSubversion also does not seem to do any custom class loading.

Because it's a terrible idea to copy a class from another plugin, as that sets you up for trouble like this. Since Subversion plugin's existed first, BlameSubversion is the copy, and hence (no pun intended) to blame.

slawomir@ezono.com (JIRA)

unread,
Oct 25, 2015, 7:28:11 AM10/25/15
to jenkinsc...@googlegroups.com

Why do you think this issue has anything to do with the BlameSubversion plugin? If GitHub is right, the BlameSubversion project has no changes for 3 years. BlameSubversion also does not seem to do any custom class loading.

Because the problem doesn't appear with a custom version of BlameSubversion plugin where I've SVNRevisionState from BlameSubversion plugin to BlameSVNRevisionState.

If anybody's interested the modified version of the plugin is here - https://github.com/ezjenkins/BlameSubversion-plugin

slawomir@ezono.com (JIRA)

unread,
Oct 25, 2015, 7:30:03 AM10/25/15
to jenkinsc...@googlegroups.com
Slawomir Czarko edited a comment on Bug JENKINS-26318
{quote}Why do you think this issue has anything to do with the BlameSubversion plugin? If GitHub is right, the BlameSubversion project has no changes for 3 years. BlameSubversion also does not seem to do any custom class loading.{quote}

Because the problem doesn't appear with a custom version of BlameSubversion plugin where I've
 renamed  SVNRevisionState  class  from BlameSubversion plugin to BlameSVNRevisionState.


If anybody's interested the modified version of the plugin is here - https://github.com/ezjenkins/BlameSubversion-plugin

schristou88@gmail.com (JIRA)

unread,
Oct 25, 2015, 8:21:09 AM10/25/15
to jenkinsc...@googlegroups.com

I created PR 1 a while ago to provide compatibility with the blame subversion plugin, and svnkit 1.8.

slawomir@ezono.com (JIRA)

unread,
Jan 26, 2016, 3:30:03 AM1/26/16
to jenkinsc...@googlegroups.com

4uva4ok@gmail.com (JIRA)

unread,
Jan 26, 2016, 4:15:02 AM1/26/16
to jenkinsc...@googlegroups.com

I hope they will do test\check\merge on you pull request as soon as possible.

4uva4ok@gmail.com (JIRA)

unread,
Jan 26, 2016, 4:15:06 AM1/26/16
to jenkinsc...@googlegroups.com
John Smith edited a comment on Bug JENKINS-26318
I hope they will do test\check\merge on  you  your  pull request as soon as possible.

bade@ieee.org (JIRA)

unread,
Jan 9, 2017, 10:48:02 AM1/9/17
to jenkinsc...@googlegroups.com

I have had this issue for over 2 years (cannot be cast error) in my production Jenkins. Over the Christmas break I did a update to the latest Java and Jenkins and all plugins, and finally found that this was the cause of the issue. Does someone have a .hpi file with this fix available? (from https://github.com/ezjenkins/BlameSubversion-plugin)

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

bade@ieee.org (JIRA)

unread,
Jan 9, 2017, 12:16:02 PM1/9/17
to jenkinsc...@googlegroups.com
Stephen Bade edited a comment on Bug JENKINS-26318
I have had this issue for over 2 years (cannot be cast error) in my production Jenkins. Over the Christmas break I did a update to the latest Java and Jenkins and all plugins, and finally found that this was the cause of the issue. Does someone have a . hpi jpi file with this fix available? (from https://github.com/ezjenkins/BlameSubversion-plugin)
- Or pointers on instructions to create the plugin? I tried building from: https://github.com/ezjenkins/BlameSubversion-plugin.git, no luck yet. That made a '.hpl' file that I assume is for Hudson, not Jenkins.

slawomir@ezono.com (JIRA)

unread,
Jan 10, 2017, 4:33:02 AM1/10/17
to jenkinsc...@googlegroups.com

.hpi file works with Jenkins as well.

Btw, I stopped using this plug-in altogether about half a year ago. I don't remember what was the exact reason but it was still causing problems even with the patches.

4uva4ok@gmail.com (JIRA)

unread,
Jan 10, 2017, 4:38:02 AM1/10/17
to jenkinsc...@googlegroups.com

Stephen Bade hpi works in Jenkins by default. Try to install your hpi file via "Manage Jenkins \ Manage Plugins \ Advanced \ Upload Plugin"

bade@ieee.org (JIRA)

unread,
Jan 10, 2017, 1:38:02 PM1/10/17
to jenkinsc...@googlegroups.com

Thanks for the tips! I found that my downstream jobs can still send emails to culprits without this plugin - the upstream build launches several downsream test jobs with the parameterized trigger plugin with the option to pass SVN revisions. I still would like an EVN var in the downstream job to print the SVN revision, but this is working. I may try this plugin again when it is more stable.
This plugin is a great idea but it would be nice to have some kind of stability info in the plugin index that to help people avoid trouble. This might be hard to manage though.

bade@ieee.org (JIRA)

unread,
Jan 18, 2017, 1:26:03 PM1/18/17
to jenkinsc...@googlegroups.com

My last comment about passing SVN revisions turned out to not work after all.
For my flow I do need this plugin. (build job launches multiple test jobs, test jobs update to the same SVN revision and sends emails to culprits)

My flow is fixed now - I did a build (mvn package) using source from https://github.com/ezjenkins/BlameSubversion-plugin.git
Thanks for the fix!

If this helps anyone I put a copy of my build's .hpi file at:
http://solidcode.org/downloads/BlameSubversion.hpi
(sorry - website is very out of date, there is no HTML link).
Hopefully the official plugin will be fixed soon.

bade@ieee.org (JIRA)

unread,
Jan 18, 2017, 1:27:04 PM1/18/17
to jenkinsc...@googlegroups.com
Stephen Bade edited a comment on Bug JENKINS-26318
Reply all
Reply to author
Forward
0 new messages