Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "chore: upgrade to node 18" #34496

Merged
merged 5 commits into from
Apr 10, 2024
Merged

Revert "chore: upgrade to node 18" #34496

merged 5 commits into from
Apr 10, 2024

Conversation

feanil
Copy link
Contributor

@feanil feanil commented Apr 9, 2024

Reverts #34311

Failing paver assets build:

TASK [edxapp : gather static assets with paver and pull translations] **********
fatal: [10.4.11.211]: FAILED! => {
    "changed": true,
    "cmd": [
        "/edx/bin/edxapp-update-assets"
    ],
    "delta": "0:00:16.132696",
    "end": "2024-04-09 16:53:18.010833",
    "rc": 1,
    "start": "2024-04-09 16:53:01.878137"
}

STDOUT:

---> pavelib.assets.update_assets
---> pavelib.prereqs.install_node_prereqs
NO_PREREQ_INSTALL is set, not installing prereqs
---> pavelib.prereqs.install_python_prereqs
NO_PREREQ_INSTALL is set, not installing prereqs
---> pavelib.assets.webpack
python manage.py lms --settings=production print_setting STATIC_ROOT WEBPACK_CONFIG_PATH 2>/edx/app/edxapp/edx-platform/test_root/log/print_settings.log
python manage.py cms --settings=production print_setting STATIC_ROOT 2>/edx/app/edxapp/edx-platform/test_root/log/print_settings.log
python manage.py cms --settings=production print_setting JS_ENV_EXTRA_CONFIG 2>/edx/app/edxapp/edx-platform/test_root/log/print_settings.log --json
NODE_ENV=production STATIC_ROOT_LMS=/edx/var/edxapp/staticfiles STATIC_ROOT_CMS=/edx/var/edxapp/staticfiles/studio JS_ENV_EXTRA_CONFIG="{}" webpack --config=webpack.prod.config.js


Captured Task Output:
---------------------

---> pavelib.assets.update_assets
---> pavelib.prereqs.install_node_prereqs
---> pavelib.prereqs.install_python_prereqs
---> pavelib.assets.webpack
python manage.py lms --settings=production print_setting STATIC_ROOT WEBPACK_CONFIG_PATH 2>/edx/app/edxapp/edx-platform/test_root/log/print_settings.log
python manage.py cms --settings=production print_setting STATIC_ROOT 2>/edx/app/edxapp/edx-platform/test_root/log/print_settings.log
python manage.py cms --settings=production print_setting JS_ENV_EXTRA_CONFIG 2>/edx/app/edxapp/edx-platform/test_root/log/print_settings.log --json
NODE_ENV=production STATIC_ROOT_LMS=/edx/var/edxapp/staticfiles STATIC_ROOT_CMS=/edx/var/edxapp/staticfiles/studio JS_ENV_EXTRA_CONFIG="{}" webpack --config=webpack.prod.config.js

Build failed running pavelib.assets.update_assets: Subprocess return code: 2

[webpack-cli] Failed to load '/edx/app/edxapp/edx-platform/webpack.prod.config.js' config
[webpack-cli] TypeError: webpack.optimize.UglifyJsPlugin is not a constructor
    at Object.<anonymous> (/edx/app/edxapp/edx-platform/webpack.prod.config.js:26:13)
    at Module._compile (node:internal/modules/cjs/loader:1364:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1422:10)
    at Module.load (node:internal/modules/cjs/loader:1203:32)
    at Module._load (node:internal/modules/cjs/loader:1019:12)
    at Module.require (node:internal/modules/cjs/loader:1231:19)
    at require (node:internal/modules/helpers:177:18)
    at WebpackCLI.tryRequireThenImport (/edx/app/edxapp/edx-platform/node_modules/webpack-cli/lib/webpack-cli.js:223:30)
    at loadConfigByPath (/edx/app/edxapp/edx-platform/node_modules/webpack-cli/lib/webpack-cli.js:1406:38)
    at /edx/app/edxapp/edx-platform/node_modules/webpack-cli/lib/webpack-cli.js:1460:88

We're still investigating so might not need this but getting it ready just in-case.

@dianakhuang dianakhuang force-pushed the revert-34311-node-18 branch from 619b0a1 to 2d7e04d Compare April 10, 2024 13:02
@dianakhuang dianakhuang force-pushed the revert-34311-node-18 branch from 2d7e04d to 98b6d6f Compare April 10, 2024 13:05
@dianakhuang
Copy link
Contributor

We were seeing issues with XBlock rendering with these changes.

Uncaught TypeError: Cannot read properties of undefined (reading 'prototype')
    at lms-application.e137e602d358.js:1:3845
    at constructBlock (lms-application.e137e602d358.js:1:3872)
    at initializeBlock (lms-application.e137e602d358.js:1:4505)
    at HTMLDivElement.<anonymous> (lms-application.e137e602d358.js:1:2921)
    at lms-main_vendor.5fc10bc4905c.js:1:1314
    at Function.map (lms-main_vendor.5fc10bc4905c.js:1:4947)
    at jQuery.fn.init.map (lms-main_vendor.5fc10bc4905c.js:1:1272)
    at initializeBlockLikes (lms-application.e137e602d358.js:1:2891)
    at Object.initializeXBlocks (lms-application.e137e602d358.js:1:4828)
    at initializeBlock (lms-application.e137e602d358.js:1:4311)

Something about the new webpack config is not loading XBlockToXModuleShim correctly, which breaks the loading of several XBlocks, including videos.

@dianakhuang dianakhuang merged commit eb26333 into master Apr 10, 2024
66 checks passed
@dianakhuang dianakhuang deleted the revert-34311-node-18 branch April 10, 2024 13:58
@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX staging environment in preparation for a release to production.

brian-smith-tcril added a commit to brian-smith-tcril/edx-platform that referenced this pull request Apr 10, 2024
@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX production environment.

1 similar comment
@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX production environment.

@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX staging environment in preparation for a release to production.

@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX production environment.

1 similar comment
@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX production environment.

kdmccormick added a commit to overhangio/tutor that referenced this pull request Apr 11, 2024
This reverts commit ab2689a,
as the upstream Node upgrade was reverted: openedx/edx-platform#34496
brian-smith-tcril added a commit to brian-smith-tcril/edx-platform that referenced this pull request Apr 12, 2024
brian-smith-tcril added a commit to brian-smith-tcril/edx-platform that referenced this pull request Apr 19, 2024
feanil pushed a commit that referenced this pull request Apr 23, 2024
revert: revert: "chore: upgrade to node 18" (#34496)
KyryloKireiev pushed a commit to raccoongang/edx-platform that referenced this pull request Apr 24, 2024
* Revert "chore: upgrade to node 18"

* Revert "fix: bump npm from 10.2.x to 10.5.x"

This reverts commit b6662d4.

* Revert "fix: replace outdated webpack plugins"

This reverts commit b204f1b.

* Revert "build: Remove the `npm bin` calls from package.json"

This reverts commit 4e3dd16.

* fix: fix bad conflict resolution.

---------

Co-authored-by: Diana Huang <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants