Bug 38770 - Remove @vue/cli-service and babel
Summary: Remove @vue/cli-service and babel
Status: Pushed to main
Alias: None
Product: Koha
Classification: Unclassified
Component: Architecture, internals, and plumbing (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal
Assignee: Victor Grousset/tuxayo
QA Contact: Martin Renvoize (ashimema)
URL:
Keywords:
Depends on: 37824
Blocks: 38167 38426
  Show dependency treegraph
 
Reported: 2024-12-22 08:25 UTC by Victor Grousset/tuxayo
Modified: 2025-01-16 22:35 UTC (History)
2 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
This removes unused dependencies following the move from webpack to Rspack (Bug 37824 - added to Koha 24.11). They were blocking upgrading ESLint and Node.js
Version(s) released in:
25.05.00
Circulation function:


Attachments
Bug 38770 - Remove @vue/cli-service and babel (2.03 KB, patch)
2024-12-22 08:34 UTC, Victor Grousset/tuxayo
Details | Diff | Splinter Review
Bug 38770: Remove @vue/cli-service and babel (2.60 KB, patch)
2024-12-22 08:52 UTC, Victor Grousset/tuxayo
Details | Diff | Splinter Review
Bug 38770: [DO NOT PUSH] yarn.lock changes (175.20 KB, patch)
2024-12-22 08:53 UTC, Victor Grousset/tuxayo
Details | Diff | Splinter Review
Bug 38770: Remove @vue/cli-service and babel (2.65 KB, patch)
2024-12-26 18:30 UTC, David Nind
Details | Diff | Splinter Review
Bug 38770: [DO NOT PUSH] yarn.lock changes (175.25 KB, patch)
2024-12-26 18:30 UTC, David Nind
Details | Diff | Splinter Review
Bug 38770: Remove @vue/cli-service and babel (2.68 KB, patch)
2025-01-03 03:02 UTC, Victor Grousset/tuxayo
Details | Diff | Splinter Review
Bug 38770: [DO NOT PUSH] yarn.lock changes (174.27 KB, patch)
2025-01-03 23:20 UTC, Victor Grousset/tuxayo
Details | Diff | Splinter Review
Bug 38770: Remove @vue/cli-service and babel (2.65 KB, patch)
2025-01-04 09:16 UTC, David Nind
Details | Diff | Splinter Review
Bug 38770: Remove @vue/cli-service and babel (2.72 KB, patch)
2025-01-07 15:19 UTC, Martin Renvoize (ashimema)
Details | Diff | Splinter Review
Bug 38770: Remove @vue/cli-service and babel (2.95 KB, patch)
2025-01-16 14:32 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Victor Grousset/tuxayo 2024-12-22 08:25:38 UTC
It's needed for bug 38167 and Bug 38426.
Comment 1 Victor Grousset/tuxayo 2024-12-22 08:34:43 UTC Comment hidden (obsolete)
Comment 2 Victor Grousset/tuxayo 2024-12-22 08:52:59 UTC
Created attachment 175886 [details] [review]
Bug 38770: Remove @vue/cli-service and babel

And the webpack related dead config.

Test plan:
1. Do not apply
2. Switch to node 22
     sudo sed 's/18.x/22.x/g' -i /etc/apt/sources.list.d/nodesource.list
     sudo apt update ; sudo apt install nodejs
3. Try to install node deps
     sudo yarn install --modules-folder /kohadevbox/node_modules
4. It fails
     error @achrinza/node-ipc@9.2.5: The engine "node" is incompatible with this module.
     Expected version "8 || 9 || 10 || 11 || 12 || 13 || 14 || 15 || 16 || 17 || 18". Got "22.12.0"
5. Apply patches
6. Try to install node deps
     sudo yarn install --modules-folder /kohadevbox/node_modules
7. It works! :)
Comment 3 Victor Grousset/tuxayo 2024-12-22 08:53:02 UTC
Created attachment 175887 [details] [review]
Bug 38770: [DO NOT PUSH] yarn.lock changes
Comment 4 David Nind 2024-12-26 18:30:37 UTC
Created attachment 175947 [details] [review]
Bug 38770: Remove @vue/cli-service and babel

And the webpack related dead config.

Test plan:
1. Do not apply
2. Switch to node 22
     sudo sed 's/18.x/22.x/g' -i /etc/apt/sources.list.d/nodesource.list
     sudo apt update ; sudo apt install nodejs
3. Try to install node deps
     sudo yarn install --modules-folder /kohadevbox/node_modules
4. It fails
     error @achrinza/node-ipc@9.2.5: The engine "node" is incompatible with this module.
     Expected version "8 || 9 || 10 || 11 || 12 || 13 || 14 || 15 || 16 || 17 || 18". Got "22.12.0"
5. Apply patches
6. Try to install node deps
     sudo yarn install --modules-folder /kohadevbox/node_modules
7. It works! :)

Signed-off-by: David Nind <david@davidnind.com>
Comment 5 David Nind 2024-12-26 18:30:40 UTC
Created attachment 175948 [details] [review]
Bug 38770: [DO NOT PUSH] yarn.lock changes

Signed-off-by: David Nind <david@davidnind.com>
Comment 6 David Nind 2024-12-26 18:33:57 UTC
Everything worked as per the test plan.

I got these warnings after applying the patch - not sure if these need fixing:

sudo yarn install --modules-folder /kohadevbox/node_modules
yarn install v1.22.22
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
warning "@redocly/cli > redoc > @cfaester/enzyme-adapter-react-18@0.8.0" has unmet peer dependency "enzyme@^3.11.0".
warning " > eslint-config-prettier@9.1.0" has unmet peer dependency "eslint@>=7.0.0".
warning " > eslint-plugin-prettier@5.1.3" has unmet peer dependency "eslint@>=8.0.0".
warning " > eslint-plugin-prettier@5.1.3" has unmet peer dependency "prettier@>=3.0.0".
warning "swagger-cli > @apidevtools/swagger-cli > @apidevtools/swagger-parser@10.1.0" has unmet peer dependency "openapi-types@>=7".
[4/4] Building fresh packages...
Done in 41.20s.
Comment 7 Victor Grousset/tuxayo 2024-12-26 20:49:21 UTC
> I got these warnings after applying the patch - not sure if these need fixing:

They will be fixed by bug 38149.
Thanks for the conscientious testing :)
Comment 8 Victor Grousset/tuxayo 2025-01-03 03:02:00 UTC
Created attachment 176114 [details] [review]
Bug 38770: Remove @vue/cli-service and babel

And the webpack related dead config.

Test plan:
1. Do not apply
2. Switch to node 22
     sudo sed 's/18.x/22.x/g' -i /etc/apt/sources.list.d/nodesource.list
     sudo apt update ; sudo apt install nodejs
3. Try to install node deps
     sudo yarn install --modules-folder /kohadevbox/node_modules
4. It fails
     error @achrinza/node-ipc@9.2.5: The engine "node" is incompatible with this module.
     Expected version "8 || 9 || 10 || 11 || 12 || 13 || 14 || 15 || 16 || 17 || 18". Got "22.12.0"
5. Apply patches
6. Try to install node deps
     sudo yarn install --modules-folder /kohadevbox/node_modules
7. It works! :)

Signed-off-by: David Nind <david@davidnind.com>
Comment 9 Victor Grousset/tuxayo 2025-01-03 03:02:39 UTC
Rebased.
Comment 10 David Nind 2025-01-03 17:57:54 UTC
The patch no longer applies 8-(...

git bz apply 38770

Bug 38770 - Remove @vue/cli-service and babel

175948 - Bug 38770: [DO NOT PUSH] yarn.lock changes
176114 - Bug 38770: Remove @vue/cli-service and babel

Apply? [(y)es, (n)o, (i)nteractive] y
Applying: Bug 38770: [DO NOT PUSH] yarn.lock changes
Applying: Bug 38770: Remove @vue/cli-service and babel
Using index info to reconstruct a base tree...
M	package.json
M	t/cypress/plugins/index.js
Falling back to patching base and 3-way merge...
Auto-merging t/cypress/plugins/index.js
CONFLICT (content): Merge conflict in t/cypress/plugins/index.js
Auto-merging package.json
error: Failed to merge in the changes.
Patch failed at 0001 Bug 38770: Remove @vue/cli-service and babel
Comment 11 Victor Grousset/tuxayo 2025-01-03 21:32:51 UTC
The conflict I solved yesterday was not legit. Likely the result of testing another patch related to prettier. (and committing the result???).

So I rollbacked the attachment changes. And it applies :)
Comment 12 Victor Grousset/tuxayo 2025-01-03 23:20:46 UTC
Created attachment 176143 [details] [review]
Bug 38770: [DO NOT PUSH] yarn.lock changes

Signed-off-by: David Nind <david@davidnind.com>
Comment 13 Victor Grousset/tuxayo 2025-01-04 08:33:22 UTC
It is simply not possible to have this being applicable alone and in bug 38524 deps at the same time. Because a dependency of 38524 (Bug 38149 but I'm not sure) conflicts with this (38770) on yarn.lock. So solving the conflicts for the case of 38770 alone and the case for having 38770 in the dependency tree of 38524 is not possible at the same time.

Whatever, let's try to not have any yarn.lock patch.
yarn install is ran in the test plans. And I don't think that even help using the sandboxes. It's just to have a clean working directory I guess?
Comment 14 David Nind 2025-01-04 09:16:08 UTC
Created attachment 176144 [details] [review]
Bug 38770: Remove @vue/cli-service and babel

And the webpack related dead config.

Test plan:
1. Do not apply
2. Switch to node 22
     sudo sed 's/18.x/22.x/g' -i /etc/apt/sources.list.d/nodesource.list
     sudo apt update ; sudo apt install nodejs
3. Try to install node deps
     sudo yarn install --modules-folder /kohadevbox/node_modules
4. It fails
     error @achrinza/node-ipc@9.2.5: The engine "node" is incompatible with this module.
     Expected version "8 || 9 || 10 || 11 || 12 || 13 || 14 || 15 || 16 || 17 || 18". Got "22.12.0"
5. Apply patches
6. Try to install node deps
     sudo yarn install --modules-folder /kohadevbox/node_modules
7. It works! :)

Signed-off-by: David Nind <david@davidnind.com>
Comment 15 Martin Renvoize (ashimema) 2025-01-07 15:19:25 UTC
Created attachment 176192 [details] [review]
Bug 38770: Remove @vue/cli-service and babel

And the webpack related dead config.

Test plan:
1. Do not apply
2. Switch to node 22
     sudo sed 's/18.x/22.x/g' -i /etc/apt/sources.list.d/nodesource.list
     sudo apt update ; sudo apt install nodejs
3. Try to install node deps
     sudo yarn install --modules-folder /kohadevbox/node_modules
4. It fails
     error @achrinza/node-ipc@9.2.5: The engine "node" is incompatible with this module.
     Expected version "8 || 9 || 10 || 11 || 12 || 13 || 14 || 15 || 16 || 17 || 18". Got "22.12.0"
5. Apply patches
6. Try to install node deps
     sudo yarn install --modules-folder /kohadevbox/node_modules
7. It works! :)

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 16 Katrin Fischer 2025-01-10 17:03:40 UTC
I had quite a bit of trouble with some tests, even after updating the yarn.lock file. I am not sure if this one is to blame or 38149 and dependencies. 
Help appreciated in untangling this next week.
Comment 17 Jonathan Druart 2025-01-16 14:32:57 UTC
Created attachment 176668 [details] [review]
Bug 38770: Remove @vue/cli-service and babel

And the webpack related dead config.

Test plan:
1. Do not apply
2. Switch to node 22
     sudo sed 's/18.x/22.x/g' -i /etc/apt/sources.list.d/nodesource.list
     sudo apt update ; sudo apt install nodejs
3. Try to install node deps
     sudo yarn install --modules-folder /kohadevbox/node_modules
4. It fails
     error @achrinza/node-ipc@9.2.5: The engine "node" is incompatible with this module.
     Expected version "8 || 9 || 10 || 11 || 12 || 13 || 14 || 15 || 16 || 17 || 18". Got "22.12.0"
5. Apply patches
6. Try to install node deps
     sudo yarn install --modules-folder /kohadevbox/node_modules
7. It works! :)

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 18 Katrin Fischer 2025-01-16 14:35:41 UTC
Apply? [(y)es, (n)o, (i)nteractive] y
Applying: Bug 38770: Remove @vue/cli-service and babel
error: sha1 information is lacking or useless (package.json).
error: could not build fake ancestor
Patch failed at 0001 Bug 38770: Remove @vue/cli-service and babel
hint: Use 'git am --show-current-patch=diff' to see the failed patch
When you have resolved this problem run "git bz apply --continue".
If you would prefer to skip this patch, instead run "git bz apply --skip".
To restore the original branch and stop patching run "git bz apply --abort".
Patch left in /tmp/Bug-38770-Remove-vuecli-service-and-babel-5oxgc_mh.patch
Comment 19 Katrin Fischer 2025-01-16 14:57:43 UTC
Pushed for 25.05!

Well done everyone, thank you!