jenkinsci / plasticscm-plugin

A plugin for Jenkins to be able to use Plastic SCM
MIT License
16 stars 31 forks source link

Global shared library doesn't work only for first pipeline using it. #11

Closed LarsUlrichKrieg closed 5 years ago

LarsUlrichKrieg commented 5 years ago

Somehow a jenkins job crashes if it is not the first one using a global shared library: [Global_Plastic_Lib] $ "C:\Program Files\PlasticSCM5\client\cm.exe" unco --all D:\jenkins\Test_script_Pipeline_Global@libs\Global_Plastic_Lib d:\jenkins\Test_script_Pipeline_Global@libs\Global_Plastic_Lib is not in a workspace. [Global_Plastic_Lib] $ "C:\Program Files\PlasticSCM5\client\cm.exe" unco --all D:\jenkins\Test_script_Pipeline_Global@libs\Global_Plastic_Lib d:\jenkins\Test_script_Pipeline_Global@libs\Global_Plastic_Lib is not in a workspace. [Global_Plastic_Lib] $ "C:\Program Files\PlasticSCM5\client\cm.exe" unco --all D:\jenkins\Test_script_Pipeline_Global@libs\Global_Plastic_Lib d:\jenkins\Test_script_Pipeline_Global@libs\Global_Plastic_Lib is not in a workspace. FATAL: The cm command 'unco' failed after 3 retries FATAL: null ERROR: null org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed: WorkflowScript: Loading libraries failed

1 error

at org.codehaus.groovy.control.ErrorCollector.failIfErrors(ErrorCollector.java:310)
at org.codehaus.groovy.control.CompilationUnit.applyToPrimaryClassNodes(CompilationUnit.java:1085)
at org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:603)
at org.codehaus.groovy.control.CompilationUnit.processPhaseOperations(CompilationUnit.java:581)
at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:558)
at groovy.lang.GroovyClassLoader.doParseClass(GroovyClassLoader.java:298)
at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:268)
at groovy.lang.GroovyShell.parseClass(GroovyShell.java:688)
at groovy.lang.GroovyShell.parse(GroovyShell.java:700)
at org.jenkinsci.plugins.workflow.cps.CpsGroovyShell.doParse(CpsGroovyShell.java:129)
at org.jenkinsci.plugins.workflow.cps.CpsGroovyShell.reparse(CpsGroovyShell.java:123)
at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.parseScript(CpsFlowExecution.java:517)
at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.start(CpsFlowExecution.java:480)
at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:269)
at hudson.model.ResourceController.execute(ResourceController.java:97)
at hudson.model.Executor.run(Executor.java:421)

Finished: FAILURE

LarsUlrichKrieg commented 5 years ago

Let me k now if you need additional information

mig42 commented 5 years ago

Hi @LarsUlrichKrieg ,

Which plasticscm-plugin version are you currently using? I'd say that version 2.18 should fix you issue... https://plugins.jenkins.io/plasticscm-plugin

LarsUlrichKrieg commented 5 years ago

I'm using version 2.19

mig42 commented 5 years ago

Thanks for the feedback, I'll share this issue with the team.

LarsUlrichKrieg commented 5 years ago

By the way: The above shown log was collected for the Build named Test_script_Pipeline_Global. Another Build was run befor that named Test_script_Pipeline_Global2.

mig42 commented 5 years ago

Hi @LarsUlrichKrieg !

I'm glad to notify that this issue was fixed in plasticscm-plugin version 2.22. Please upgrade your plugin version and try it out! If you run into any further issues please open a new one here referencing this one.

Thank you!