Issue
After upgrading controllers to version 2.426.3.3, some jobs appear to failed with the following stack trace:
net.sf.json.JSONException: JSONObject["scm"] is not a JSONObject. at net.sf.json.JSONObject.getJSONObject(JSONObject.java:2006) at hudson.scm.SCMS.parseSCM(SCMS.java:57) at hudson.model.AbstractProject.submit(AbstractProject.java:1833) at hudson.model.Project.submit(Project.java:228) at hudson.model.Job.doConfigSubmit(Job.java:1359) at hudson.model.AbstractProject.doConfigSubmit(AbstractProject.java:775) at java.base/java.lang.invoke.MethodHandle.invokeWithArguments(MethodHandle.java:710) at org.kohsuke.stapler.Function$MethodFunction.invoke(Function.java:397) at org.kohsuke.stapler.Function$InstanceFunction.invoke(Function.java:409) at org.kohsuke.stapler.Function.bindAndInvoke(Function.java:207) at org.kohsuke.stapler.SelectionInterceptedFunction$Adapter.invoke(SelectionInterceptedFunction.java:36) at org.kohsuke.stapler.verb.HttpVerbInterceptor.invoke(HttpVerbInterceptor.java:48) at org.kohsuke.stapler.SelectionInterceptedFunction.bindAndInvoke(SelectionInterceptedFunction.java:26) at org.kohsuke.stapler.Function.bindAndInvokeAndServeResponse(Function.java:140) at org.kohsuke.stapler.MetaClass$11.doDispatch(MetaClass.java:558) at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:59) at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:770) at org.kohsuke.stapler.Stapler.invoke(Stapler.java:900) at org.kohsuke.stapler.MetaClass$4.doDispatch(MetaClass.java:289) ...
Resolution
Upgrade the Build Timeout plugin to version 1.32 or newer.
Workaround
A problem was detected when the instance has Github plugin and Build Timeout plugin installed. The Build Timeout plugin is a Tier 3 plugin, so the main workaround is to disable the Build Timeout plugin which causes the issue.
Tested product/plugin versions
-
Cloudbees CI Controller 2.426.3.3
-
Github plugin 1.37.3.1
-
Build timeout plugin < 1.32
This article is part of our Knowledge Base and is provided for guidance-based purposes only. The solutions or workarounds described here are not officially supported by CloudBees and may not be applicable in all environments. Use at your own discretion, and test changes in a safe environment before applying them to production systems.