Skip to content

Add defensiveness against missing language for recommendations #5125

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

Merged
merged 3 commits into from
Jun 26, 2025

Conversation

bjester
Copy link
Member

@bjester bjester commented Jun 18, 2025

Summary

  • Ensures we only show the recommendations iff we have a valid request
  • Adds defensive route guard that ensures currentChannel is loaded, which is used for recommendation request's fallback language
  • Updates le-utils to latest version, which includes schema changes, and corresponding changes implemented

References

fixes #5111

Reviewer guidance

  1. Have a public channel from production, such as KA, imported into your local instance
  2. Open a new channel, and create a folder hierarchy for recommendations, e.g. Elementary > Math > Algebra
  3. Open the destination folder (e.g. Algebra)
  4. Click ADD, then 'Import from channels'
  5. Verify recommendations show
  6. Refresh the page with the import modal open
  7. Verify recommendations appear again

@bjester bjester force-pushed the recommendation-language branch from 3b7b419 to 0344acf Compare June 24, 2025 17:30
@bjester bjester marked this pull request as ready for review June 24, 2025 17:54
@bjester bjester requested review from akolson and ozer550 June 24, 2025 17:54
@bjester
Copy link
Member Author

bjester commented Jun 24, 2025

⚠️ Requires that we merge this first, or otherwise break recommendations on unstable

@bjester bjester force-pushed the recommendation-language branch from 13d4fd8 to 0339896 Compare June 26, 2025 18:00
Copy link
Member

@akolson akolson left a comment

Choose a reason for hiding this comment

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

Code changes make sense to me. Thanks @bjester

@bjester bjester merged commit 5a96a25 into learningequality:unstable Jun 26, 2025
13 checks passed
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.

Schema validation error: '' does not match '^[a-z]{2,3}(?:-[a-zA-Z]+)?$'
2 participants