From 35e000f2ce0f16fe104f9fd83ccd8c4bd4fddc3d Mon Sep 17 00:00:00 2001 From: "Adolfo R. Brandes" Date: Mon, 9 Dec 2024 10:33:58 -0300 Subject: [PATCH] feat: Force-enable navigation sidebar in upgrade to Sumac When upgrading to Sumac, forcefully enable the Learning MFE's navigation sidebar. --- ..._arbrandes_force_enable_navigation_sidebar_in_upgrade.md | 1 + tutor/commands/upgrade/common.py | 6 ++++++ 2 files changed, 7 insertions(+) create mode 100644 changelog.d/20241209_103522_arbrandes_force_enable_navigation_sidebar_in_upgrade.md diff --git a/changelog.d/20241209_103522_arbrandes_force_enable_navigation_sidebar_in_upgrade.md b/changelog.d/20241209_103522_arbrandes_force_enable_navigation_sidebar_in_upgrade.md new file mode 100644 index 0000000000..7a98871cf4 --- /dev/null +++ b/changelog.d/20241209_103522_arbrandes_force_enable_navigation_sidebar_in_upgrade.md @@ -0,0 +1 @@ +[Improvement] Forcefully enable the Learning MFE's navigation sidebar when upgrading to Sumac. (by @arbrandes) diff --git a/tutor/commands/upgrade/common.py b/tutor/commands/upgrade/common.py index 7a54995f80..2c4d47be2e 100644 --- a/tutor/commands/upgrade/common.py +++ b/tutor/commands/upgrade/common.py @@ -47,6 +47,12 @@ def upgrade_from_nutmeg(context: click.Context, config: Config) -> None: def upgrade_from_redwood(context: click.Context, config: Config) -> None: + # Forcefully enable the learning MFE's navigation sidebar. + if plugins.is_loaded("mfe"): + context.obj.job_runner(config).run_task( + "lms", "./manage.py lms waffle_flag --create --everyone courseware.enable_navigation_sidebar" + ) + # Prevent switching to the MySQL storage backend in forum v2 if plugins.is_loaded("forum"): fmt.echo_alert(