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

Add Waffle flags to roll out the extracted XBlocks #35549

Draft
wants to merge 11 commits into
base: master
Choose a base branch
from

Conversation

farhan
Copy link
Contributor

@farhan farhan commented Sep 26, 2024

Add Waffle flags to roll out the extracted XBlocks
Flags will use to toggle between the old and new block quickly
without putting course content or user state at risk.

Testing notes:

It requires to restart lms/cms to put the waffle flag into effect

Ticket: #35308

Waffle Flags

Following built in blocks wafffle flags are in action in this PR and has been implemented:

  • word_cloud
  • annotatable
  • poll_question
  • lti
  • html
  • discussion
  • problem
  • video

Current Status:

  • Waffle flags word_cloud, annotatable, poll_question, lti, html has been tested on lms and cms
  • Waffle flags discussion, problem, video has been tested on lms and cms
    • They are currently reverted because of excessive amount of test cases were failing.

Next action items:

  • Fix all the test cases related to word_cloud, annotatable, poll_question, lti, html
  • Put back implementation of discussion, problem, video (one by one if required)
  • Fix all the test cases

@farhan farhan force-pushed the farhan/waffle-flag-for-extracted-xblock branch 2 times, most recently from cabc843 to 64cf575 Compare October 2, 2024 09:31
@farhan farhan changed the title Test PR Add Waffle flags to roll out the extracted XBlocks Oct 2, 2024
@farhan farhan marked this pull request as ready for review October 2, 2024 10:02
@farhan farhan force-pushed the farhan/waffle-flag-for-extracted-xblock branch 3 times, most recently from 4ed8c6d to 34d042c Compare October 14, 2024 08:59
@farhan farhan linked an issue Oct 14, 2024 that may be closed by this pull request
@farhan farhan force-pushed the farhan/waffle-flag-for-extracted-xblock branch 2 times, most recently from cca34ec to b2dcc10 Compare October 16, 2024 16:17
@farhan farhan force-pushed the farhan/waffle-flag-for-extracted-xblock branch 2 times, most recently from 833b935 to 9820dd6 Compare October 27, 2024 06:38
@farhan farhan closed this Oct 28, 2024
@farhan farhan reopened this Oct 28, 2024
@farhan farhan force-pushed the farhan/waffle-flag-for-extracted-xblock branch 3 times, most recently from 9eb768c to 84aba33 Compare October 31, 2024 08:38
@farhan farhan force-pushed the farhan/waffle-flag-for-extracted-xblock branch from 84aba33 to 73ddfa0 Compare November 6, 2024 07:07
@farhan farhan added the create-sandbox open-craft-grove should create a sandbox environment from this PR label Nov 6, 2024
@open-craft-grove
Copy link

Sandbox deployment failed 💥
Please check the settings and requirements.
Retry deployment by pushing a new commit or updating the requirements/settings in the pull request's description.
📜 Failure Logs
ℹ️ Grove Config, Tutor Config, Tutor Requirements

@open-craft-grove
Copy link

Sandbox deployment failed 💥
Please check the settings and requirements.
Retry deployment by pushing a new commit or updating the requirements/settings in the pull request's description.
📜 Failure Logs
ℹ️ Grove Config, Tutor Config, Tutor Requirements

@farhan farhan force-pushed the farhan/waffle-flag-for-extracted-xblock branch from a2e4584 to 73ddfa0 Compare November 6, 2024 08:15
@open-craft-grove
Copy link

Sandbox deployment failed 💥
Please check the settings and requirements.
Retry deployment by pushing a new commit or updating the requirements/settings in the pull request's description.
📜 Failure Logs
ℹ️ Grove Config, Tutor Config, Tutor Requirements

@farhan farhan force-pushed the farhan/waffle-flag-for-extracted-xblock branch 4 times, most recently from 681020d to 6c91c56 Compare November 7, 2024 11:43
@open-craft-grove
Copy link

Sandbox deployment successful 🚀
🎓 LMS
📝 Studio
ℹ️ Grove Config, Tutor Config, Tutor Requirements

@open-craft-grove
Copy link

Sandbox deployment successful 🚀
🎓 LMS
📝 Studio
ℹ️ Grove Config, Tutor Config, Tutor Requirements

xmodule/toggles.py Outdated Show resolved Hide resolved
@farhan farhan closed this Nov 8, 2024
@farhan farhan reopened this Nov 8, 2024
@farhan farhan closed this Nov 8, 2024
@farhan farhan reopened this Nov 8, 2024
@kdmccormick kdmccormick marked this pull request as draft November 12, 2024 16:12
@kdmccormick
Copy link
Member

Looking good so far. Let's keep this marked as a Draft until the changeset is ready for review.

@farhan farhan marked this pull request as ready for review November 12, 2024 16:41
@farhan farhan force-pushed the farhan/waffle-flag-for-extracted-xblock branch 3 times, most recently from 20c7c1a to 8948e1b Compare November 13, 2024 09:22
@farhan farhan marked this pull request as draft November 13, 2024 09:34
@farhan farhan force-pushed the farhan/waffle-flag-for-extracted-xblock branch from ea7803a to 1df53ab Compare November 13, 2024 10:41
farhan and others added 5 commits November 15, 2024 13:37
chore: Update xblocks-contrib pypi package

Commit generated by workflow `openedx/edx-platform/.github/workflows/upgrade-one-python-dependency.yml@refs/heads/farhan/waffle-flag-for-extracted-xblock`
@farhan farhan force-pushed the farhan/waffle-flag-for-extracted-xblock branch from 5c4b985 to e38730a Compare November 15, 2024 08:37
@farhan farhan force-pushed the farhan/waffle-flag-for-extracted-xblock branch from 1ca5ece to 8a86b48 Compare November 18, 2024 05:28
@farhan
Copy link
Contributor Author

farhan commented Nov 18, 2024

@kdmccormick
Please review the initial steps of this PR and guide us either we are in right direction, specially how we are fixing test cases.

cc: @irtazaakram @ttqureshi

@farhan farhan self-assigned this Nov 18, 2024
@kdmccormick
Copy link
Member

Thanks for the ping @farhan ... reviewing your unit test fixes, it's become clear that my suggested approach is flawed 😓

It seems that we cannot use Waffle flags at the level of the module, because Django is not yet ready to access the database at module-load time. You have figured out a clever workaround for unit tests, but this would not solve the issue at runtime.

I am experimenting with some alternatives right now. I'll let you know what I find.

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.

Add Waffle flags to roll out extracted XBlocks
4 participants