[JIRA] (JENKINS-38047) Allow multiple positional (i.e., unnamed) parameters in Pipeline Model Definition steps etc

2 views
Skip to first unread message

andrew.bayer@gmail.com (JIRA)

unread,
Sep 7, 2016, 9:01:01 PM9/7/16
to jenkinsc...@googlegroups.com
Andrew Bayer created an issue
 
Jenkins / Improvement JENKINS-38047
Allow multiple positional (i.e., unnamed) parameters in Pipeline Model Definition steps etc
Issue Type: Improvement Improvement
Assignee: Andrew Bayer
Components: pipeline-model-definition-plugin
Created: 2016/Sep/08 1:00 AM
Environment: Pipeline Model 0.1
Priority: Critical Critical
Reporter: Andrew Bayer

The declarative subset rule says that if you have multiple parameters to a step/function/whatever in the model, they have to be named parameters. That's causing problems - any pre-existing global library method with multiple parameters (and a closure body - not 100% sure this bombs out when you don't have a closure body, but this is bad enough as is!) will not work outside of a script block. That'd be bad enough on its own, but wait, it gets worse! The sandbox is somehow swallowing the MissingMethodException that's getting thrown when Groovy is looking for someMethod(Map, CpsClosure), resulting in the method never being executed without any error or explanation. That, my friends, is Bad.

So...since I can't figure out how to deal with that swallowed exception for the life of me, I'm intending to remove the named parameters requirement. Yay.

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

andrew.bayer@gmail.com (JIRA)

unread,
Sep 7, 2016, 9:39:03 PM9/7/16
to jenkinsc...@googlegroups.com
Andrew Bayer started work on Improvement JENKINS-38047
 
Change By: Andrew Bayer
Status: Open In Progress

andrew.bayer@gmail.com (JIRA)

unread,
Sep 7, 2016, 9:41:02 PM9/7/16
to jenkinsc...@googlegroups.com

andrew.bayer@gmail.com (JIRA)

unread,
Sep 7, 2016, 9:41:02 PM9/7/16
to jenkinsc...@googlegroups.com

andrew.bayer@gmail.com (JIRA)

unread,
Sep 8, 2016, 12:16:03 PM9/8/16
to jenkinsc...@googlegroups.com

scm_issue_link@java.net (JIRA)

unread,
Sep 8, 2016, 12:16:03 PM9/8/16
to jenkinsc...@googlegroups.com
SCM/JIRA link daemon commented on Improvement JENKINS-38047
 
Re: Allow multiple positional (i.e., unnamed) parameters in Pipeline Model Definition steps etc

Code changed in jenkins
User: Andrew Bayer
Path:
SYNTAX.md
src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTPositionalArgumentList.groovy
src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTValue.groovy
src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/JSONParser.groovy
src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/ModelParser.groovy
src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/validator/ModelValidator.groovy
src/main/resources/ast-schema.json
src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/AbstractModelDefTest.java
src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/BasicModelDefTest.java
src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/ValidatorTest.java
src/test/resources/errors/globalLibraryUnnamedParameters.groovy
src/test/resources/globalLibrarySuccess.groovy
src/test/resources/json/globalLibrarySuccess.json
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/080ae00ba0c5c0b301a98019b1c69bb604a2c83a
Log:
[FIXED JENKINS-38047] Allow multiple positional parameters.

Phew. That was kind of nutty.

bitwiseman@gmail.com (JIRA)

unread,
Oct 22, 2019, 11:24:42 PM10/22/19
to jenkinsc...@googlegroups.com
Liam Newman closed an issue as Fixed
 

Bulk closing resolved issues.

Change By: Liam Newman
Status: Resolved Closed
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo
Reply all
Reply to author
Forward
0 new messages