mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-12 16:22:17 -05:00
switch to raw_get and raw_set to see exceptions
This commit is contained in:
@@ -78,7 +78,7 @@ def send_sms_to_provider(notification):
|
||||
)
|
||||
except BaseException:
|
||||
key = f"2facode-{notification.id}".replace(" ", "")
|
||||
my_phone = redis_store.get(key)
|
||||
my_phone = redis_store.raw_get(key)
|
||||
|
||||
if my_phone:
|
||||
my_phone = my_phone.decode("utf-8")
|
||||
|
||||
@@ -352,7 +352,7 @@ def create_2fa_code(
|
||||
)
|
||||
|
||||
current_app.logger.info("TESTING REDIS")
|
||||
redis_store.set("TESTKEY5", "WORKS")
|
||||
redis_store.raw_set("TESTKEY5", "WORKS")
|
||||
current_app.logger.info(f"SHOULD SEE THE WORD 'WORKS' HERE: {redis_store.get('TESTKEY5')}")
|
||||
|
||||
key = f"2facode-{saved_notification.id}".replace(" ", "")
|
||||
@@ -361,8 +361,8 @@ def create_2fa_code(
|
||||
current_app.logger.info(
|
||||
f"IN REST, WHERE WE SET THE VALUE, KEY IS {key} and value is {recipient}"
|
||||
)
|
||||
redis_store.set(key, recipient)
|
||||
stored_recipient = redis_store.get(key)
|
||||
redis_store.raw_set(key, recipient)
|
||||
stored_recipient = redis_store.raw_get(key)
|
||||
# TODO REMOVE
|
||||
current_app.logger.info(
|
||||
f"IN REST, WHERE WE GET THE VALUE, KEY IS {key} and value is {stored_recipient}"
|
||||
|
||||
Reference in New Issue
Block a user