Skip to content

[BACKPORT] feat: Implement feature flag to disable students un-enrollment (#29326) - #30348

Merged
nedbat merged 1 commit into
openedx:open-release/maple.masterfrom
open-craft:0x29a/bb4951/maple-backport
May 24, 2022
Merged

[BACKPORT] feat: Implement feature flag to disable students un-enrollment (#29326)#30348
nedbat merged 1 commit into
openedx:open-release/maple.masterfrom
open-craft:0x29a/bb4951/maple-backport

Conversation

@0x29a

@0x29a 0x29a commented May 5, 2022

Copy link
Copy Markdown
Contributor

Description

This is the backport of #29326.

The cherry-pick wasn't clean:

diff --cc cms/envs/common.py
index 974e99370a,b21e07ee99..0000000000
--- a/cms/envs/common.py
+++ b/cms/envs/common.py
@@@ -472,10 -479,59 +472,50 @@@ FEATURES =
      # .. toggle_target_removal_date: 2021-10-01
      # .. toggle_tickets: 'https://openedx.atlassian.net/browse/MICROBA-1405'
      'ENABLE_V2_CERT_DISPLAY_SETTINGS': False,
++<<<<<<< HEAD
++=======
+
+     # .. toggle_name: FEATURES['ENABLE_INTEGRITY_SIGNATURE']
+     # .. toggle_implementation: DjangoSetting
+     # .. toggle_default: False
+     # .. toggle_description: Whether to replace ID verification course/certificate requirement
+     # with an in-course Honor Code agreement
+     # (https://github.com/edx/edx-name-affirmation)
+     # .. toggle_use_cases: open_edx
+     # .. toggle_creation_date: 2022-02-15
+     # .. toggle_target_removal_date: None
+     # .. toggle_tickets: 'https://openedx.atlassian.net/browse/MST-1348'
+     'ENABLE_INTEGRITY_SIGNATURE': False,
+
+     # .. toggle_name: MARK_LIBRARY_CONTENT_BLOCK_COMPLETE_ON_VIEW
+     # .. toggle_implementation: DjangoSetting
+     # .. toggle_default: False
+     # .. toggle_description: If enabled, the Library Content Block is marked as complete when users view it.
+     #   Otherwise (by default), all children of this block must be completed.
+     # .. toggle_use_cases: open_edx
+     # .. toggle_creation_date: 2022-03-22
+     # .. toggle_target_removal_date: None
+     # .. toggle_tickets: https://github.com/edx/edx-platform/pull/28268
+     # .. toggle_warnings: For consistency in user-experience, keep the value in sync with the setting of the same name
+     #   in the LMS and CMS.
+     'MARK_LIBRARY_CONTENT_BLOCK_COMPLETE_ON_VIEW': False,
+
+     # .. toggle_name: FEATURES['DISABLE_UNENROLLMENT']
+     # .. toggle_implementation: DjangoSetting
+     # .. toggle_default: False
+     # .. toggle_description: Set to True to disable self-unenrollments via REST API.
+     #   This also hides the "Unenroll" button on the Learner Dashboard.
+     # .. toggle_use_cases: open_edx
+     # .. toggle_creation_date: 2021-10-11
+     # .. toggle_warnings: For consistency in user experience, keep the value in sync with the setting of the same name
+     #   in the LMS and CMS.
+     # .. toggle_tickets: 'https://github.com/open-craft/edx-platform/pull/429'
+     'DISABLE_UNENROLLMENT': False,
++>>>>>>> da4a6d6103... feat: Implement feature flag to disable students un-enrollment (#29326)
  }

 -# .. toggle_name: ENABLE_COPPA_COMPLIANCE
 -# .. toggle_implementation: DjangoSetting
 -# .. toggle_default: False
 -# .. toggle_description: When True, inforces COPPA compliance and removes YOB field from registration form and accounnt
 -# .. settings page. Also hide YOB banner from profile page.
 -# .. toggle_use_cases: open_edx
 -# .. toggle_creation_date: 2021-10-27
 -# .. toggle_tickets: 'https://openedx.atlassian.net/browse/VAN-622'
 -ENABLE_COPPA_COMPLIANCE = False
 -
  ENABLE_JASMINE = False

 -MARKETING_EMAILS_OPT_IN = False
 -
  # List of logout URIs for each IDA that the learner should be logged out of when they logout of the LMS. Only applies to
  # IDA for which the social auth flow uses DOT (Django OAuth Toolkit).
  IDA_LOGOUT_URI_LIST = []
diff --cc lms/envs/common.py
index 958d06ccbf,da7fd16b2c..0000000000
--- a/lms/envs/common.py
+++ b/lms/envs/common.py
@@@ -948,6 -961,55 +948,58 @@@ FEATURES =
      # .. toggle_target_removal_date: 2021-10-01
      # .. toggle_tickets: 'https://openedx.atlassian.net/browse/MICROBA-1405'
      'ENABLE_V2_CERT_DISPLAY_SETTINGS': False,
++<<<<<<< HEAD
++=======
+
+     # .. toggle_name: FEATURES['ENABLE_INTEGRITY_SIGNATURE']
+     # .. toggle_implementation: DjangoSetting
+     # .. toggle_default: False
+     # .. toggle_description: Whether to replace ID verification course/certificate requirement
+     # with an in-course Honor Code agreement
+     # (https://github.com/edx/edx-name-affirmation)
+     # .. toggle_use_cases: open_edx
+     # .. toggle_creation_date: 2022-02-15
+     # .. toggle_target_removal_date: None
+     # .. toggle_tickets: 'https://openedx.atlassian.net/browse/MST-1348'
+     'ENABLE_INTEGRITY_SIGNATURE': False,
+
+     # .. toggle_name: FEATURES['ENABLE_NEW_BULK_EMAIL_EXPERIENCE']
+     # .. toggle_implementation: DjangoSetting
+     # .. toggle_default: False
+     # .. toggle_description: When true, replaces the bulk email tool found on the
+     #   instructor dashboard with a link to the new communications MFE version instead.
+     #   Stting the tool to false will leave the old bulk email tool experience in place.
+     # .. toggle_use_cases: opt_in
+     # .. toggle_creation_date: 2022-03-21
+     # .. toggle_target_removal_date: None
+     # .. toggle_tickets: 'https://openedx.atlassian.net/browse/MICROBA-1758'
+     'ENABLE_NEW_BULK_EMAIL_EXPERIENCE': False,
+
+     # .. toggle_name: MARK_LIBRARY_CONTENT_BLOCK_COMPLETE_ON_VIEW
+     # .. toggle_implementation: DjangoSetting
+     # .. toggle_default: False
+     # .. toggle_description: If enabled, the Library Content Block is marked as complete when users view it.
+     #   Otherwise (by default), all children of this block must be completed.
+     # .. toggle_use_cases: open_edx
+     # .. toggle_creation_date: 2022-03-22
+     # .. toggle_target_removal_date: None
+     # .. toggle_tickets: https://github.com/edx/edx-platform/pull/28268
+     # .. toggle_warnings: For consistency in user-experience, keep the value in sync with the setting of the same name
+     #   in the LMS and CMS.
+     'MARK_LIBRARY_CONTENT_BLOCK_COMPLETE_ON_VIEW': False,
+
+     # .. toggle_name: FEATURES['DISABLE_UNENROLLMENT']
+     # .. toggle_implementation: DjangoSetting
+     # .. toggle_default: False
+     # .. toggle_description: Set to True to disable self-unenrollments via REST API.
+     #   This also hides the "Unenroll" button on the Learner Dashboard.
+     # .. toggle_use_cases: open_edx
+     # .. toggle_creation_date: 2021-10-11
+     # .. toggle_warnings: For consistency in user experience, keep the value in sync with the setting of the same name
+     #   in the LMS and CMS.
+     # .. toggle_tickets: 'https://github.com/open-craft/edx-platform/pull/429'
+     'DISABLE_UNENROLLMENT': False,
++>>>>>>> da4a6d6103... feat: Implement feature flag to disable students un-enrollment (#29326)
  }

  # Specifies extra XBlock fields that should available when requested via the Course Blocks API

…dx#29326)

Implements a feature flag DISABLE_UNENROLLMENT that is used to disable students un-enrollment for all courses. The Unenrollment option should be disabled when this feature is set to True.

ref: BB-4951

Co-authored-by: tinumide <tinuade@opencraft.com>
Co-authored-by: Tim McCormack <tmccormack@edx.org>
(cherry picked from commit da4a6d6)
@openedx-webhooks

Copy link
Copy Markdown

Thanks for the pull request, @0x29a! I've created OSPR-6658 to keep track of it in JIRA, where we prioritize reviews. Please note that it may take us up to several weeks or months to complete a review and merge your PR.

Feel free to add as much of the following information to the ticket as you can:

  • supporting documentation
  • Open edX discussion forum threads
  • timeline information ("this must be merged by XX date", and why that is)
  • partner information ("this is a course on edx.org")
  • any other information that can help Product understand the context for the PR

All technical communication about the code itself will be done via the GitHub pull request interface. As a reminder, our process documentation is here.

Please let us know once your PR is ready for our review and all tests are green.

@openedx-webhooks openedx-webhooks added needs triage open-source-contribution PR author is not from Axim or 2U labels May 5, 2022
@natabene

natabene commented May 6, 2022

Copy link
Copy Markdown
Contributor

@0x29a Thank you for your contribution. Is this ready for our review?

@openedx-webhooks openedx-webhooks added awaiting prioritization waiting on author PR author needs to resolve review requests, answer questions, fix tests, etc. and removed needs triage awaiting prioritization labels May 6, 2022
@0x29a

0x29a commented May 9, 2022

Copy link
Copy Markdown
Contributor Author

Yes, it's ready, @natabene.

@openedx-webhooks openedx-webhooks added awaiting prioritization and removed waiting on author PR author needs to resolve review requests, answer questions, fix tests, etc. labels May 12, 2022
@natabene

Copy link
Copy Markdown
Contributor

@BbrSofiane Can you please review this backport to Maple?

@BbrSofiane BbrSofiane left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@BbrSofiane

Copy link
Copy Markdown
Contributor

@openedx/edx-community-bot merge

@BbrSofiane

Copy link
Copy Markdown
Contributor

@edx-community-bot merge

@0x29a

0x29a commented May 23, 2022

Copy link
Copy Markdown
Contributor Author

@BbrSofiane, thank you for reviewing this! Any chance this can be merged before open-release/maple.4 tagging?

@nedbat
nedbat merged commit 36b0a19 into openedx:open-release/maple.master May 24, 2022
@openedx-webhooks

Copy link
Copy Markdown

@0x29a 🎉 Your pull request was merged! Please take a moment to answer a two question survey so we can improve your experience in the future.

@nedbat

nedbat commented May 24, 2022

Copy link
Copy Markdown
Contributor

The required comment is "@openedx-community-bot merge", but I'm still confused by the logic of the auto-merge bot if the PR was made by someone else and approved by @BbrSofiane.

@BbrSofiane

Copy link
Copy Markdown
Contributor

Thanks @nedbat!

Hmm I checked the workflow and I think see what you mean. The current implementation would only work if someone in the merger list is opens the PR is that correct?

It doesn't look like it worked for openedx/enterprise-catalog#453 even though Max was the author.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merged open-source-contribution PR author is not from Axim or 2U

Projects

Archived in project
Archived in project

Development

Successfully merging this pull request may close these issues.

5 participants