-
Bug
-
Resolution: Unresolved
-
Minor
-
None
Jenkins.instance.copy is not working anymore since update to 2.249.3
Following code...
def jenkins = Jenkins.instance def strTemplateName = 'Folder/_componentTemplate' def strNewJobFullName = 'Folder/jobs/01_folder/jobs/jobname' def template = jenkins.getItemByFullName(strTemplateName) // Create new job based on template println 'Creating new job: ' + strNewJobFullName; def job = jenkins.copy(template,strNewJobPath)
...leads now to the following error:
hudson.model.Failure: ‘/’ is an unsafe character at jenkins.model.Jenkins.checkGoodName(Jenkins.java:4031) at hudson.model.ItemGroupMixIn.copy(ItemGroupMixIn.java:238) at jenkins.model.Jenkins.copy(Jenkins.java:3995) at sun.reflect.GeneratedMethodAccessor1566.invoke(Unknown Source) ...