From a7a86304b794db3ebf8a54f5abc5e200fc14b012 Mon Sep 17 00:00:00 2001 From: Andy McKay Date: Tue, 27 Nov 2012 13:32:50 -0800 Subject: [PATCH] seclusion is dead, long live solitude --- lib/pay_server/__init__.py | 12 ++++++------ lib/pay_server/test.py | 4 ++-- lib/settings_base.py | 15 +++++++-------- sites/altdev/settings_mkt.py | 2 +- sites/dev/settings_mkt.py | 2 +- sites/landfill/settings_mkt.py | 2 +- sites/stage/settings_mkt.py | 2 +- 7 files changed, 19 insertions(+), 20 deletions(-) diff --git a/lib/pay_server/__init__.py b/lib/pay_server/__init__.py index a7cd266304..01c6d4fdcf 100644 --- a/lib/pay_server/__init__.py +++ b/lib/pay_server/__init__.py @@ -160,15 +160,15 @@ class ZamboniClient(Client): def get_client(): - # If you haven't specified a seclusion host, we can't do anything. - if settings.SECLUSION_HOSTS: + # If you haven't specified a solitude host, we can't do anything. + if settings.SOLITUDE_HOSTS: config = { # TODO: when seclusion can cope with multiple hosts, we'll pass # them all through and let seclusion do its magic. - 'server': settings.SECLUSION_HOSTS[0], - 'key': settings.SECLUSION_KEY, - 'secret': settings.SECLUSION_SECRET, - 'timeout': settings.SECLUSION_TIMEOUT + 'server': settings.SOLITUDE_HOSTS[0], + 'key': settings.SOLITUDE_KEY, + 'secret': settings.SOLITUDE_SECRET, + 'timeout': settings.SOLITUDE_TIMEOUT } client = ZamboniClient(config) client.encoder = ZamboniEncoder diff --git a/lib/pay_server/test.py b/lib/pay_server/test.py index 9bbe58b529..1daf165a8a 100644 --- a/lib/pay_server/test.py +++ b/lib/pay_server/test.py @@ -16,7 +16,7 @@ from lib.pay_server import (client, filter_encoder, model_to_uid, from lib.pay_server.errors import codes, lookup -@patch.object(settings, 'SECLUSION_HOSTS', ('http://localhost')) +@patch.object(settings, 'SOLITUDE_HOSTS', ('http://localhost')) @patch.object(settings, 'DOMAIN', 'testy') class TestUtils(test_utils.TestCase): @@ -124,7 +124,7 @@ class TestUtils(test_utils.TestCase): eq_(kwargs['data']['paypal_id'], 'foo') -@patch.object(settings, 'SECLUSION_HOSTS', ('http://localhost')) +@patch.object(settings, 'SOLITUDE_HOSTS', ('http://localhost')) @patch.object(settings, 'DOMAIN', 'testy') class TestPay(test_utils.TestCase): diff --git a/lib/settings_base.py b/lib/settings_base.py index 7328263aa0..dd6e6c761c 100644 --- a/lib/settings_base.py +++ b/lib/settings_base.py @@ -1467,16 +1467,15 @@ IN_TEST_SUITE = False # Flip this on in your local settings to experience the joy of ES tests. RUN_ES_TESTS = False -# The configuration for seclusion the client that speaks to solitude. -# A tuple of the solitude hosts that seclusion will speak to. -SECLUSION_HOSTS = ('',) +# The configuration for the client that speaks to solitude. +# A tuple of the solitude hosts. +SOLITUDE_HOSTS = ('',) # The oAuth key and secret that solitude needs. -SECLUSION_KEY = '' -SECLUSION_SECRET = '' -# The timeout we'll give seclusion. Since this often involves calling Paypal or -# other servers, we are including that in this. -SECLUSION_TIMEOUT = 10 +SOLITUDE_KEY = '' +SOLITUDE_SECRET = '' +# The timeout we'll give solitude. +SOLITUDE_TIMEOUT = 10 # Temporary flag to work with navigator.mozPay() on devices that don't # support it natively. diff --git a/sites/altdev/settings_mkt.py b/sites/altdev/settings_mkt.py index b6b3b10788..96ca6abd5b 100644 --- a/sites/altdev/settings_mkt.py +++ b/sites/altdev/settings_mkt.py @@ -110,7 +110,7 @@ INAPP_KEY_PATHS = private_mkt.INAPP_KEY_PATHS WEBAPP_MANIFEST_NAME = 'Mozilla Marketplace (Dev)' -SECLUSION_HOSTS = ('https://payments-dev.allizom.org',) +SOLITUDE_HOSTS = ('https://payments-dev.allizom.org',) PAYPAL_LIMIT_PREAPPROVAL = False diff --git a/sites/dev/settings_mkt.py b/sites/dev/settings_mkt.py index 7477a11a69..fba5398bd3 100644 --- a/sites/dev/settings_mkt.py +++ b/sites/dev/settings_mkt.py @@ -113,7 +113,7 @@ INAPP_KEY_PATHS = private_mkt.INAPP_KEY_PATHS WEBAPP_MANIFEST_NAME = 'Mozilla Marketplace (Dev)' -SECLUSION_HOSTS = ('https://payments-dev.allizom.org',) +SOLITUDE_HOSTS = ('https://payments-dev.allizom.org',) PAYPAL_LIMIT_PREAPPROVAL = False diff --git a/sites/landfill/settings_mkt.py b/sites/landfill/settings_mkt.py index 86e8a81dea..b81beae196 100644 --- a/sites/landfill/settings_mkt.py +++ b/sites/landfill/settings_mkt.py @@ -110,7 +110,7 @@ INAPP_KEY_PATHS = private_mkt.INAPP_KEY_PATHS WEBAPP_MANIFEST_NAME = 'Mozilla Marketplace (Dev)' -SECLUSION_HOSTS = ('https://payments-dev.allizom.org',) +SOLITUDE_HOSTS = ('https://payments-dev.allizom.org',) PAYPAL_LIMIT_PREAPPROVAL = False diff --git a/sites/stage/settings_mkt.py b/sites/stage/settings_mkt.py index 46fef8ca8e..af9fd06bcc 100644 --- a/sites/stage/settings_mkt.py +++ b/sites/stage/settings_mkt.py @@ -104,7 +104,7 @@ VALIDATOR_IAF_URLS = ['https://marketplace.firefox.com', 'https://marketplace.allizom.org', 'https://marketplace-dev.allizom.org'] -SECLUSION_HOSTS = ('https://payments.allizom.org',) +SOLITUDE_HOSTS = ('https://payments.allizom.org',) GEOIP_NOOP = 0