Skip to content

Commit

Permalink
Merge pull request #979 from shankari/fix_push
Browse files Browse the repository at this point in the history
🐛 Change the way in which we read the configuration variables
  • Loading branch information
shankari authored Sep 12, 2024
2 parents 9fe1b3e + 6eac178 commit de250e7
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions emission/net/ext_service/push/notify_interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,9 @@
"PUSH_APP_PACKAGE_NAME": "app_package_name", "PUSH_IOS_TOKEN_FORMAT": "ios_token_format"})

try:
logging.info(f"Push configured for app {push_config.get('PUSH_SERVER_AUTH_TOKEN')} using platform {os.getenv('PUSH_PROVIDER')} with token {os.getenv('PUSH_SERVER_AUTH_TOKEN')[:10]}... of length {len(os.getenv('PUSH_SERVER_AUTH_TOKEN'))}")
except:
logging.warning(f"Push configured for app {push_config.get('PUSH_APP_PACKAGE_NAME')} using platform {push_config.get('PUSH_PROVIDER')} with token {push_config.get('PUSH_SERVER_AUTH_TOKEN')[:10]}... of length {len(push_config.get('PUSH_SERVER_AUTH_TOKEN'))}")
except Exception as e:
logging.exception(e)
logging.warning("push service not configured, push notifications not supported")

class NotifyInterfaceFactory(object):
Expand Down

0 comments on commit de250e7

Please sign in to comment.