diff --git a/static/js/blueslip.js b/static/js/blueslip.js index 3dda297020..a01f375af4 100644 --- a/static/js/blueslip.js +++ b/static/js/blueslip.js @@ -168,7 +168,7 @@ function report_error(msg, stack, opts) { } }); - if (page_params.staging) { + if (page_params.save_stacktraces) { // Save the stacktrace so it can be examined even in // development servers. (N.B. This assumes you have set DEBUG // = False on your development server, or else this code path diff --git a/zerver/tests/tests.py b/zerver/tests/tests.py index c95d8b2762..ad891c73ac 100644 --- a/zerver/tests/tests.py +++ b/zerver/tests/tests.py @@ -1798,10 +1798,10 @@ class HomeTest(AuthedTestCase): "realm_name", "realm_restricted_to_domain", "referrals", + "save_stacktraces", "share_the_love", "show_digest_email", "sounds_enabled", - "staging", "stream_desktop_notifications_enabled", "stream_sounds_enabled", "subbed_info", diff --git a/zerver/views/__init__.py b/zerver/views/__init__.py index 24f5e604f4..c797ada3b2 100644 --- a/zerver/views/__init__.py +++ b/zerver/views/__init__.py @@ -985,7 +985,7 @@ def home(request): max_message_id = register_ret['max_message_id'], unread_count = approximate_unread_count(user_profile), furthest_read_time = sent_time_in_epoch_seconds(latest_read), - staging = settings.ZULIP_COM_STAGING or settings.DEVELOPMENT, + save_stacktraces = settings.SAVE_FRONTEND_STACKTRACES, alert_words = register_ret['alert_words'], muted_topics = register_ret['muted_topics'], realm_filters = register_ret['realm_filters'], diff --git a/zproject/dev_settings.py b/zproject/dev_settings.py index d1612c0f3e..dcff10f3cb 100644 --- a/zproject/dev_settings.py +++ b/zproject/dev_settings.py @@ -22,3 +22,4 @@ EXTRA_INSTALLED_APPS = ["zilencer", "analytics"] CAMO_URI = '' OPEN_REALM_CREATION = True +SAVE_FRONTEND_STACKTRACES = True diff --git a/zproject/local_settings.py b/zproject/local_settings.py index 01de8b5a62..e41294ca9f 100644 --- a/zproject/local_settings.py +++ b/zproject/local_settings.py @@ -56,6 +56,7 @@ if ZULIP_COM_STAGING: EXTERNAL_HOST = 'staging.zulip.com' STATSD_PREFIX = 'staging' STAGING_ERROR_NOTIFICATIONS = True + SAVE_FRONTEND_STACKTRACES = True else: EXTERNAL_HOST = 'zulip.com' EXTERNAL_API_PATH = 'api.zulip.com' diff --git a/zproject/settings.py b/zproject/settings.py index b94d897f3c..2c4dfb3714 100644 --- a/zproject/settings.py +++ b/zproject/settings.py @@ -114,6 +114,7 @@ DEFAULT_SETTINGS = {'TWITTER_CONSUMER_KEY': '', 'DROPBOX_APP_KEY': '', 'ERROR_REPORTING': True, 'STAGING_ERROR_NOTIFICATIONS': False, + 'SAVE_FRONTEND_STACKTRACES': False, 'JWT_AUTH_KEYS': {}, 'NAME_CHANGES_DISABLED': False, 'DEPLOYMENT_ROLE_NAME': "",