Skip to content

Instantly share code, notes, and snippets.

@ynevet
Last active March 1, 2022 16:29
Show Gist options
  • Save ynevet/acf076bcddac3afe65890db5be6e5088 to your computer and use it in GitHub Desktop.
Save ynevet/acf076bcddac3afe65890db5be6e5088 to your computer and use it in GitHub Desktop.
Fail fast and loudly example
def _get_remote_config_value(self, path: str) -> str:
try:
_, resp = self._config_client.kv.get(path)
val = resp['Value'].decode()
return val
except Exception as e:
print(f'Fail to get remote configuration for key = {path}')
raise e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment