Skip to content

Lower Tutor MFE version pin - #1089

Merged
bmtcril merged 6 commits into
mainfrom
bmtcril/lower_tutor_mfe_pin
Aug 1, 2025
Merged

Lower Tutor MFE version pin#1089
bmtcril merged 6 commits into
mainfrom
bmtcril/lower_tutor_mfe_pin

Conversation

@bmtcril

@bmtcril bmtcril commented Jul 14, 2025

Copy link
Copy Markdown
Contributor

Allow this plugin to be installed on Redwood and Sumac again. Previously the MFE version pin forced a Tutor upgrade to Teak or higher. Documentation updated to include more references to version compatibility.

Closes: #1088

Comment thread tutoraspects/plugin.py
]
)
# If PLUGIN_SLOTS doesn't exist, we are on Redwood and do not
# support in-context metrics.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and tutor-mfe version needed to support in-context metric is v19 and above.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@farhaanbukhsh I think what I'd like to do is actually make the in-context feature toggleable across all versions but currently there doesn't seem to be a way to do that from inside the Tutor plugin (PLUGIN_SLOTS.add_items() and PLUGIN_SLOTS.add() are both called before we have the user settings which would tell us whether to add them or not.

It seems like we would have to add a runtime configuration that platform-plugin-aspects would use to determine what to do. Does that sound like the right approach to you, or is there something I'm missing?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bmtcril Let me try to understand what we are trying to do. We will create a toggle in platform-plugin-aspects, which opens up a toggle in-context API that determines if in-context metrics will be displayed or not.

Why do we need this?

The feature is still toggleable by ASPECTS_ENABLE_STUDIO_IN_CONTEXT_METRICS, but if you want to do it at the env.config.js level or PLUGIN_SLOTS level, maybe we can add a gate here, or we can eliminate the use of PLUGIN_SLOTS.add_item by writing directly to https://github.com/openedx/tutor-contrib-aspects/blob/643aeec1e56c3fc3e0851f34740b241de07ad448/tutoraspects/patches/mfe-env-config-runtime-definitions-authoring

But these will be done at build time and not at runtime.

Let me know if I am not able to understand something.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now that I think more about it, making this a runtime toggle solution doesn't seem to be straightforward. The decision needs to be taken in env,config.js or inside the plugin slots which doesn't seem to be a good solution.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @farhaanbukhsh , ASPECTS_ENABLE_STUDIO_IN_CONTEXT_METRICS works fine even if it needs an mfe rebuild to take effect. One of the problems was that it wasn't plumbed all the way through platform-plugin-aspects, which should be fixed here: openedx/platform-plugin-aspects#163

I think between that PR and this one (with an upgrade of platform-plugin-aspects) it will allow older versions of both Aspects and Tutor (back to Redwood) to work as long as that flag is False.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bmtcril sounds right :) thank you for the amazing work.

Only in-context metrics requires mfe 19+ so we hope to be able to
release a version that works back to Redwood and just doesn't support
in-context metrics.
@bmtcril
bmtcril force-pushed the bmtcril/lower_tutor_mfe_pin branch from c8bc0b6 to 7ece8f5 Compare July 21, 2025 19:45
@bmtcril bmtcril changed the title TEST: Lower tutor mfe pin Lower tutor mfe pin Jul 21, 2025
@bmtcril bmtcril changed the title Lower tutor mfe pin Lower Tutor MFE version pin Jul 21, 2025
@bmtcril
bmtcril requested a review from saraburns1 July 21, 2025 19:48
@bmtcril
bmtcril force-pushed the bmtcril/lower_tutor_mfe_pin branch from 7ece8f5 to 777038b Compare July 22, 2025 16:17
settings

Allows platform-plugin-aspects to know whether to include in-context
dashboards in the request for a Superset guest token. See: openedx/platform-plugin-aspects#163
@bmtcril
bmtcril force-pushed the bmtcril/lower_tutor_mfe_pin branch from baca11b to 1ee0d78 Compare July 31, 2025 13:12
Brings in related bug fixes from platform-plugin-aspects.
@bmtcril
bmtcril force-pushed the bmtcril/lower_tutor_mfe_pin branch from 1ee0d78 to e69753c Compare July 31, 2025 14:56
@bmtcril
bmtcril merged commit 0dbeaf9 into main Aug 1, 2025
9 checks passed
@bmtcril
bmtcril deleted the bmtcril/lower_tutor_mfe_pin branch August 1, 2025 12:48
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.

Mismatched required Tutor versions in base.in

3 participants