Turn of discussion service in test env
- add a check for the feature flag before trying to save user info to the service
This commit is contained in:
@@ -282,6 +282,9 @@ def add_user_to_default_group(user, group):
|
||||
|
||||
@receiver(post_save, sender=User)
|
||||
def update_user_information(sender, instance, created, **kwargs):
|
||||
if not settings.MITX_FEATURES['ENABLE_DISCUSSION_SERVICE']:
|
||||
# Don't try--it won't work, and it will fill the logs with lots of errors
|
||||
return
|
||||
try:
|
||||
cc_user = cc.User.from_django_user(instance)
|
||||
cc_user.save()
|
||||
|
||||
@@ -16,6 +16,9 @@ from path import path
|
||||
# can test everything else :)
|
||||
MITX_FEATURES['DISABLE_START_DATES'] = True
|
||||
|
||||
# Until we have discussion actually working in test mode, just turn it off
|
||||
MITX_FEATURES['ENABLE_DISCUSSION_SERVICE'] = False
|
||||
|
||||
# Need wiki for courseware views to work. TODO (vshnayder): shouldn't need it.
|
||||
WIKI_ENABLED = True
|
||||
|
||||
|
||||
Reference in New Issue
Block a user