• Icon: Task Task
    • Resolution: Fixed
    • Icon: Minor Minor
    • release-plugin
    • None

      See this blog post for details. Prototype will eventually be removed from Jenkins core. To prepare for this transition, this plugin must be migrated away from Prototype. The blog post contains instructions on how to find and eliminate usages of Prototype. In this plugin, the following usages of Prototype have been identified. This may not be an exhaustive list:

      ./src/main/resources/hudson/plugins/release/pipeline/ReleaseStep/config.jelly:36:                var div = $$('params');
      ./src/main/resources/hudson/plugins/release/pipeline/ReleaseStep/config.jelly:37:                new Ajax.Request('${descriptor.descriptorUrl}/parameters?job=' + encodeURIComponent($$('${jobFieldId}').value) + '&context=' + encodeURIComponent('${descriptor.context}'), {
      ./src/main/resources/hudson/plugins/release/ReleaseWrapper/ReleaseAction/index.jelly:92:                                        inputElement = $$('form[action="submit"] input[value="'+pName+'"]')[0];     
      ./src/main/resources/hudson/plugins/release/ReleaseWrapper/ReleaseAction/index.jelly:96:                                                if(inputElement.next().tagName == "SELECT"){
      ./src/main/resources/hudson/plugins/release/ReleaseWrapper/ReleaseAction/index.jelly:98:                                                        inputElement.next('select').getElementsBySelector('option[value="'+fieldValue+'"]')[0].selected="selected";
      ./src/main/resources/hudson/plugins/release/ReleaseWrapper/ReleaseAction/index.jelly:100:                                                       inputElement.next('input').value=fieldValue;
      ./src/main/resources/hudson/plugins/release/ReleaseWrapper/ReleaseAction/index.jelly:108:                                                       inputElement.next('.jenkins-checkbox').getElementsBySelector('input')[0].checked=fieldValue;
      ./src/main/resources/hudson/plugins/release/ReleaseWrapper/ReleaseAction/index.jelly:119:                                       optionsArray = $$('form[action="submit"] input[value="'+pName+'"]')[0].next('select').getElementsBySelector('option');
      ./src/main/resources/hudson/plugins/release/ReleaseWrapper/ReleaseAction/index.jelly:120:                                       optionsArray.each(function(item){
      ./src/main/resources/hudson/plugins/release/ReleaseWrapper/ReleaseAction/index.jelly:126:                                               inputFields = $$('form[action="submit"] .jenkins-input');
      ./src/main/resources/hudson/plugins/release/ReleaseWrapper/ReleaseAction/index.jelly:127:                                               inputFields.each(function(item) {
      
      

          [JENKINS-71304] Remove usages of Prototype from Release

          Basil Crow added a comment -

          timja FYI

          Basil Crow added a comment - timja FYI

          Basil Crow added a comment -

          timja Any interest in working on this one? Would be great to get this crossed off the list. It has 2,897 installations so I'm not sure we can ignore it.

          Basil Crow added a comment - timja Any interest in working on this one? Would be great to get this crossed off the list. It has 2,897 installations so I'm not sure we can ignore it.

          Tim Jacomb added a comment -

          Possibly, the plugin is up for adoption though, I'm not a user of this plugin and only have commit access due to tables to divs.

          Tim Jacomb added a comment - Possibly, the plugin is up for adoption though, I'm not a user of this plugin and only have commit access due to tables to divs.

          Basil Crow added a comment -

          Sure, any help would be appreciated as I have removed Prototype from dozens of plugins at this point and fatigue is starting to set in

          Basil Crow added a comment - Sure, any help would be appreciated as I have removed Prototype from dozens of plugins at this point and fatigue is starting to set in

          Tim Jacomb added a comment - - edited

          From what I can tell all the prototype related code is for a niche case and it seems to already be broken

          Tim Jacomb added a comment - - edited From what I can tell all the prototype related code is for a niche case and it seems to already be broken

          Basil Crow added a comment -

          Hrmm, was that always broken or is it a regression from some frontend changes from the past few years?

          Basil Crow added a comment - Hrmm, was that always broken or is it a regression from some frontend changes from the past few years?

          Tim Jacomb added a comment -

          Likely tables to divs 3 years or so ago.

          I can't see any bug reports the feature is non obvious with poor UX.

          Tim Jacomb added a comment - Likely tables to divs 3 years or so ago. I can't see any bug reports the feature is non obvious with poor UX.

          Basil Crow added a comment -

          Looks like this plugin still has two usages of Prototype:

          hudson/plugins/release/pipeline/ReleaseStep/config.jelly:                new Ajax.Request('${descriptor.descriptorUrl}/parameters?job=' + encodeURIComponent($$('${jobFieldId}').value) + '&context=' + encodeURIComponent('${descriptor.context}'), {
          

          and

          hudson/plugins/release/pipeline/ReleaseStep/config.jelly:                var div = $$('params');

          Basil Crow added a comment - Looks like this plugin still has two usages of Prototype: hudson/plugins/release/pipeline/ReleaseStep/config.jelly: new Ajax.Request('${descriptor.descriptorUrl}/parameters?job=' + encodeURIComponent($$('${jobFieldId}').value) + '&context=' + encodeURIComponent('${descriptor.context}'), { and hudson/plugins/release/pipeline/ReleaseStep/config.jelly:                var div = $$('params');

            Unassigned Unassigned
            basil Basil Crow
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: