Project

General

Profile

Actions

action #159411

closed

Upgrade codemirror from 5.58.2 to 6.0.1 size:M

Added by livdywan 6 months ago. Updated 5 months ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
Feature requests
Target version:
Start date:
2024-04-22
Due date:
2024-05-10
% Done:

0%

Estimated time:

Description

Motivation

dependabot automatically prepares PR's as a new version of a dependency we rely on is available. Some of the updates require manual intervention when there's incompatible changes. We should treat them like High tickets.

codemirror 6.0.1 has been available since March 15 meaning it exceeds our SLA and we should look into it asap, hence this ticket to make it more visible.

Acceptance criteria

  • AC1: The codemirror dependency has been upgraded, replaced or otherwise handled

Suggestions

Rollback actions

  • DONE Enable auto-update service on o3
  • DONE Make sure openqa on o3 is up-to-date again

Related issues 2 (0 open2 closed)

Related to openQA Project - action #159720: [OBS] openQA packages failing with "File not found: /home/abuild/…/usr/share/openqa/node_modules" apparently on all architectures but x86_64Resolvedmkittler2024-04-292024-05-13

Actions
Copied to openQA Project - action #159663: Prevent missing js assets in PR checks as observed in #159411-11Resolvedmkittler

Actions
Actions #1

Updated by mkittler 6 months ago · Edited

Looks like CodeMirror really requires the use of a bundler, see https://codemirror.net/docs/ref. I suppose WebPack could be used (see https://github.com/codemirror/codemirror5/issues/5484) and thus perhaps also https://metacpan.org/pod/Mojolicious::Plugin::Webpack.

We also need to install packages packages for certain features manually, e.g. @codemirror/view, @codemirror/lang-yaml and @codemirror/legacy-modes, @codemirror/lang-perl and @codemirror/lang-diff. Unfortunately I couldn't actually find the last two packages. Not sure where support for this went; if those languages are no longer supported this would be quite problematic.

Note that there'd be also many alternatives: https://js.libhunt.com/codemirror-alternatives
Considering that updating CodeMirror would be quite some effort as well we should consider looking into alternatives as well:

Actions #2

Updated by okurz 6 months ago

Ok, so proof of concept for using quill or proof of concept for webpack?

Actions #3

Updated by okurz 6 months ago

  • Priority changed from High to Normal
Actions #4

Updated by mkittler 6 months ago

I'd vote for quill because that would probably be very easy to do. One just had to follow the example from https://quilljs.com/docs/modules/syntax.

Actions #5

Updated by livdywan 6 months ago

mkittler wrote in #note-4:

I'd vote for quill because that would probably be very easy to do. One just had to follow the example from https://quilljs.com/docs/modules/syntax.

Yeah, quill looks quite nice and easy to swap in the editor setup.

Actions #6

Updated by jbaier_cz 6 months ago

  • Subject changed from Upgrade codemirror from 5.58.2 to 6.0.1 to Upgrade codemirror from 5.58.2 to 6.0.1 size:M
  • Description updated (diff)
  • Status changed from New to Workable
Actions #7

Updated by mkittler 6 months ago

  • Status changed from Workable to In Progress
  • Assignee set to mkittler
Actions #9

Updated by openqa_review 6 months ago

  • Due date set to 2024-05-10

Setting due date based on mean cycle time of SUSE QE Tools

Actions #10

Updated by mkittler 6 months ago

  • Status changed from In Progress to Feedback
Actions #11

Updated by jbaier_cz 6 months ago · Edited

  • Description updated (diff)

So there is an issue with this PR, webui is refusing to start:

Apr 26 10:11:35 new-ariel systemd[1]: Started The openQA web UI.
Apr 26 10:11:36 new-ariel openqa-webui-daemon[21685]: AssetPack was unable to locate related asset '../node_modules/ace-builds/css/main-1.png' at /usr/share/openqa/script/../lib/Mojolicious/Plugin/AssetPack/Pipe/FetchForNode.pm line 25.
Apr 26 10:11:36 new-ariel systemd[1]: openqa-webui.service: Main process exited, code=exited, status=2/INVALIDARGUMENT
Apr 26 10:11:36 new-ariel systemd[1]: openqa-webui.service: Failed with result 'exit-code'.

I did zypper in --oldpackage /var/cache/zypp/packages/devel_openQA/x86_64/*-4.6.1713895143.68ea6d5a-lp155.6541.1.x86_64.rpm as a workaround and disabled auto-update systemctl disable --now openqa-auto-update.timer and systemctl disable --now openqa-continuous-update.timer

Actions #12

Updated by okurz 6 months ago

  • Copied to action #159663: Prevent missing js assets in PR checks as observed in #159411-11 added
Actions #13

Updated by okurz 6 months ago

  • Description updated (diff)
Actions #14

Updated by okurz 6 months ago

  • Description updated (diff)
Actions #15

Updated by okurz 6 months ago

fix https://github.com/os-autoinst/openQA/pull/5594 was merged. I conducted rollback steps, fixed version deployed, o3 up, checked multiple pages with editor and looks new and good, all good again. Closed revert https://github.com/os-autoinst/openQA/pull/5593

Actions #16

Updated by okurz 5 months ago

  • Related to action #159720: [OBS] openQA packages failing with "File not found: /home/abuild/…/usr/share/openqa/node_modules" apparently on all architectures but x86_64 added
Actions #17

Updated by mkittler 5 months ago

  • Status changed from Feedback to Resolved

The changes are deployed on o3 (again) and look good.

Actions

Also available in: Atom PDF