Jenkins警告发布者在构建时失败

时间:2018-06-13 20:24:15

标签: jenkins jenkins-plugins jenkins-pipeline

我有一个checkstyle阶段,创建一个flake8报告并使用警告发布者。当我运行构建时,我得到以下错误。

我已经安装了"静态分析收集器插件"同样。

withEnv(["VIR_ENV=$env.WORKSPACE/venv"]){
            stage ('Check_style') {
                 sh """
                    #. venv/bin/activate
                    export PATH=${VIRENV}/bin:${PATH}
                    echo $PATH
                    make flake8 | tee test-report/flake8.log || true
                """
                step([$class: 'WarningsPublisher',
                  parserConfigurations: [[
                    parserName: 'Pep8',
                    pattern: 'report/flake8.log'
                  ]],
                  unstableTotalAll: '0',
                  usePreviousBuildAsReference: true
                ])
            }
        }

错误: -

Build failed with Error: java.lang.IllegalArgumentException: Could not instantiate {delegate={$class=WarningsPublisher, parserConfigurations=[{parserName=Pep8, pattern=report/flake8.log}], unstableTotalAll=0, usePreviousBuildAsReference=true}} for CoreStep(delegate: 

0 个答案:

没有答案