Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-68750

Plugin Manager does not sort by timestamp (regression in 2.274)

    • 2.362

      I don't know since when, but for some time sorting in plugin manager do not work.
      I guess it's after manager upgrade.

      Instead of sorting by timestamp it sorts by date string.
      https://github.com/jenkinsci/jenkins/blob/afb7c2a96be8aed2b659e9f08677b403082c4799/core/src/main/resources/hudson/PluginManager/table.jelly#L222

      I think reason of such behavior is unsupported format and html tag. According to sortable lib this sorter should be used here.
      https://github.com/jenkinsci/jenkins/blob/cee0d06770e6bed478e105368ef57371814f3f79/war/src/main/webapp/scripts/sortable.js#L296

      In attachment you have a small preview.

          [JENKINS-68750] Plugin Manager does not sort by timestamp (regression in 2.274)

          Bartosz Nowak created issue -
          Basil Crow made changes -
          Summary Original: Plugin Manager do not sort by timestamp New: Plugin Manager does not sort by timestamp
          Basil Crow made changes -
          Labels Original: UI bug core plugin-manager regression ui New: plugin-manager ux

          Basil Crow added a comment -

          This is not a recent regression. I installed 2.277.4 (the oldest version of Jenkins still supported by the Update Center at the time of this writing) with the default list of suggested plugins and can reproduce the problem there. Because this is not a recent regression I am removing the regression label from this PR.

          Basil Crow added a comment - This is not a recent regression. I installed 2.277.4 (the oldest version of Jenkins still supported by the Update Center at the time of this writing) with the default list of suggested plugins and can reproduce the problem there. Because this is not a recent regression I am removing the regression label from this PR.
          Ian Williams made changes -
          Attachment New: pluginManager-263.4.png [ 58235 ]

          Ian Williams added a comment - - edited

          basil , sorting appears fine in 2.263.4 , so just an older regression

          Ian Williams added a comment - - edited basil , sorting appears fine in 2.263.4 , so just an older regression

          Basil Crow added a comment -

          Thanks ianw, I think this can be classified as a regression if we have steps to reproduce the problem from scratch. Since we can no longer install 2.263.4 and the suggested plugins by using the Update Center (because this core is too old), the only way to reproduce the problem from scratch would be to use a hard-coded list of plugins. The screenshot above suggests that you have such a list, could you please share it?

          Basil Crow added a comment - Thanks ianw , I think this can be classified as a regression if we have steps to reproduce the problem from scratch. Since we can no longer install 2.263.4 and the suggested plugins by using the Update Center (because this core is too old), the only way to reproduce the problem from scratch would be to use a hard-coded list of plugins. The screenshot above suggests that you have such a list, could you please share it?

          Ian Williams added a comment -

          Steps to reproduce were very easy.
          Run a clean install of Jenkins 2.263.4

          java -DJENKINS_HOME=2.263 -jar jenkins-2.236.4.war
          

          Skip the wizard steps ( so skip plugins, initial user, etc.)
          got to http://localhost:8080/pluginManager/available
          (set up proxy in Advanced first 'cos behind firewall)
          Check Now to obtain list of available plugins
          Filter on "plugin" ('cos everything is returned)
          Sort by Released , click for Up, then for Down, observe.
          Observe that under 2.263.4, the list of plugins is sorted correctly chronologically
          It's all as expected; hours, then days, months, years (see image).

          Rinse and repeat for 2.277.4

          java -DJENKINS_HOME=2.277 -jar jenkins-2.277.4.war
          

          Observe that under 2.277.4, it is not:
          1 mo, then 1 yr, 10 mo, 11, mo, then 2 mo, 2 yr, etc.

          Matrix Authorization Strategy 3.1.2 1 mo 18 days ago
          Command Agent Launcher 81.v9c2cb_cb_db_392 1 mo 23 days ago
          Jackson 2 API 2.13.3-285.vc03c0256d517 1 mo 5 days ago
          Folders 6.722.v8165b_a_cf25e9 1 mo 5 days ago
          Display URL API 2.3.5 1 yr 0 mo ago
          SCM Step 2.13 1 yr 0 mo ago
          Pipeline Graph Analysis 1.11 1 yr 0 mo ago
          Handlebars bundle 3.0.8 1 yr 2 mo ago
          Supporting APIs 3.8 1 yr 3 mo ago
          Oracle Java SE Development Kit Installer 1.5 1 yr 4 mo ago
          Apache HttpComponents Client 4.x API 4.5.13-1.0 1 yr 5 mo ago
          Trilead API 1.0.13 1 yr 6 mo ago
          SCM API 2.6.5 10 mo ago
          Basic Steps 2.24 10 mo ago
          Git client 3.9.0 11 mo ago
          Branch API 2.1045.v4ec3ed07b_e4f 2 mo 0 days ago
          Credentials 2.6.1.1 2 mo 15 days ago
          Shared Groovy Libraries 2.21.3 2 mo 16 days ago
          Build Step 2.17 2 mo 17 days ago
          JSch dependency 0.1.55.2 2 yr 4 mo ago
          SSH Credentials 1.18.1 2 yr 5 mo ago
          GIT server 1.9 2 yr 6 mo ago
          Durable Task 495.v29cd95ec10f2 3 mo 0 days ago
          API 1143.v2d42f1e9dea_5 3 mo 12 days ago
          Groovy 2660.vb_c0412dc4e6d 3 mo 19 days ago
          REST API 2.23 3 mo 19 days ago
          Script Security 1138.v8e727069a_025 3 mo 28 days ago
          Token Macro 270.v8c2ce50dc4fc 4 mo 12 days ago
          Milestone Step 100.v60a_03cd446e1 4 mo 12 days ago
          Multibranch 711.vdfef37cda_816 4 mo 2 days ago
          Plain Credentials 1.8 4 mo 26 days ago
          OWASP Markup Formatter 2.7 5 mo 10 days ago
          Step API 622.vb_8e7c15b_c95a_ 5 mo 17 days ago
          Stage Step 291.vf0a8a7aeeb50 5 mo 25 days ago
          Mailer 1.34.2 5 mo 29 days ago
          Input Step 427.va6441fa17010 6 mo 12 days ago
          Credentials Binding 1.27.1 6 mo 2 days ago
          Structs 308.v852b473a2b8c 6 mo 23 days ago
          Matrix Project 1.18.1 6 mo 5 days ago
          Job 1145.v7f2433caa07f 6 mo 6 days ago
          ACE Editor bundle 1.1 6 yr 3 mo ago
          Moment.js bundle 1.1.1 6 yr 3 mo ago
          Stage Tags Metadata 1.9.3 7 mo 4 days ago
          Model API 1.9.3 7 mo 4 days ago
          Declarative Extension Points API 1.9.3 7 mo 4 days ago
          Declarative 1.9.3 7 mo 4 days ago
          bouncycastle API 2.25 8 mo 26 days ago
          Git 4.8.3 9 mo 0 days ago
          Nodes and Processes 2.40 9 mo 1 day ago

          Ian Williams added a comment - Steps to reproduce were very easy. Run a clean install of Jenkins 2.263.4 java -DJENKINS_HOME=2.263 -jar jenkins-2.236.4.war Skip the wizard steps ( so skip plugins, initial user, etc.) got to http://localhost:8080/pluginManager/available (set up proxy in Advanced first 'cos behind firewall) Check Now to obtain list of available plugins Filter on " plugin " ('cos everything is returned) Sort by Released , click for Up , then for Down , observe. Observe that under 2.263.4, the list of plugins is sorted correctly chronologically It's all as expected; hours, then days, months, years (see image). Rinse and repeat for 2.277.4 java -DJENKINS_HOME=2.277 -jar jenkins-2.277.4.war Observe that under 2.277.4, it is not: 1 mo, then 1 yr, 10 mo, 11, mo, then 2 mo, 2 yr, etc. Matrix Authorization Strategy 3.1.2 1 mo 18 days ago Command Agent Launcher 81.v9c2cb_cb_db_392 1 mo 23 days ago Jackson 2 API 2.13.3-285.vc03c0256d517 1 mo 5 days ago Folders 6.722.v8165b_a_cf25e9 1 mo 5 days ago Display URL API 2.3.5 1 yr 0 mo ago SCM Step 2.13 1 yr 0 mo ago Pipeline Graph Analysis 1.11 1 yr 0 mo ago Handlebars bundle 3.0.8 1 yr 2 mo ago Supporting APIs 3.8 1 yr 3 mo ago Oracle Java SE Development Kit Installer 1.5 1 yr 4 mo ago Apache HttpComponents Client 4.x API 4.5.13-1.0 1 yr 5 mo ago Trilead API 1.0.13 1 yr 6 mo ago SCM API 2.6.5 10 mo ago Basic Steps 2.24 10 mo ago Git client 3.9.0 11 mo ago Branch API 2.1045.v4ec3ed07b_e4f 2 mo 0 days ago Credentials 2.6.1.1 2 mo 15 days ago Shared Groovy Libraries 2.21.3 2 mo 16 days ago Build Step 2.17 2 mo 17 days ago JSch dependency 0.1.55.2 2 yr 4 mo ago SSH Credentials 1.18.1 2 yr 5 mo ago GIT server 1.9 2 yr 6 mo ago Durable Task 495.v29cd95ec10f2 3 mo 0 days ago API 1143.v2d42f1e9dea_5 3 mo 12 days ago Groovy 2660.vb_c0412dc4e6d 3 mo 19 days ago REST API 2.23 3 mo 19 days ago Script Security 1138.v8e727069a_025 3 mo 28 days ago Token Macro 270.v8c2ce50dc4fc 4 mo 12 days ago Milestone Step 100.v60a_03cd446e1 4 mo 12 days ago Multibranch 711.vdfef37cda_816 4 mo 2 days ago Plain Credentials 1.8 4 mo 26 days ago OWASP Markup Formatter 2.7 5 mo 10 days ago Step API 622.vb_8e7c15b_c95a_ 5 mo 17 days ago Stage Step 291.vf0a8a7aeeb50 5 mo 25 days ago Mailer 1.34.2 5 mo 29 days ago Input Step 427.va6441fa17010 6 mo 12 days ago Credentials Binding 1.27.1 6 mo 2 days ago Structs 308.v852b473a2b8c 6 mo 23 days ago Matrix Project 1.18.1 6 mo 5 days ago Job 1145.v7f2433caa07f 6 mo 6 days ago ACE Editor bundle 1.1 6 yr 3 mo ago Moment.js bundle 1.1.1 6 yr 3 mo ago Stage Tags Metadata 1.9.3 7 mo 4 days ago Model API 1.9.3 7 mo 4 days ago Declarative Extension Points API 1.9.3 7 mo 4 days ago Declarative 1.9.3 7 mo 4 days ago bouncycastle API 2.25 8 mo 26 days ago Git 4.8.3 9 mo 0 days ago Nodes and Processes 2.40 9 mo 1 day ago
          Basil Crow made changes -
          Link New: This issue is caused by JENKINS-64196 [ JENKINS-64196 ]

          Basil Crow added a comment -

          Thank you for the steps to to reproduce ianw; I bisected this to jenkinsci/jenkins#5051.

          timja FYI

          Basil Crow added a comment - Thank you for the steps to to reproduce ianw ; I bisected this to jenkinsci/jenkins#5051 . timja FYI

            Unassigned Unassigned
            dumam Bartosz Nowak
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: