diff options
author | Bryan Newbold <bnewbold@robocracy.org> | 2021-12-15 18:46:19 -0800 |
---|---|---|
committer | Bryan Newbold <bnewbold@robocracy.org> | 2021-12-15 18:46:19 -0800 |
commit | cca680e2cc4768a4d45e199f6256a433b25b4075 (patch) | |
tree | c0d8d8911873b266b335be7152bda2ba8bdb044b | |
parent | 1632a07d581e4f17148378ebcc6fc6c162ee430a (diff) | |
download | fatcat-cca680e2cc4768a4d45e199f6256a433b25b4075.tar.gz fatcat-cca680e2cc4768a4d45e199f6256a433b25b4075.zip |
make fmt
-rw-r--r-- | python/fatcat_web/__init__.py | 2 | ||||
-rw-r--r-- | python/fatcat_web/web_config.py | 9 |
2 files changed, 6 insertions, 5 deletions
diff --git a/python/fatcat_web/__init__.py b/python/fatcat_web/__init__.py index a89c5bbe..c4b6309b 100644 --- a/python/fatcat_web/__init__.py +++ b/python/fatcat_web/__init__.py @@ -3,6 +3,7 @@ from typing import Any import elasticsearch import fatcat_openapi_client +import sentry_sdk from authlib.flask.client import OAuth from flask import Flask from flask.logging import create_logger @@ -13,7 +14,6 @@ from flask_mwoauth import MWOAuth from flask_uuid import FlaskUUID from flask_wtf.csrf import CSRFProtect from loginpass import GitHub, Gitlab, ORCiD, create_flask_blueprint -import sentry_sdk from sentry_sdk.integrations.flask import FlaskIntegration from fatcat_web.types import AnyResponse diff --git a/python/fatcat_web/web_config.py b/python/fatcat_web/web_config.py index 005986bd..55d233f3 100644 --- a/python/fatcat_web/web_config.py +++ b/python/fatcat_web/web_config.py @@ -42,14 +42,15 @@ def test_bool_str() -> None: assert bool_str("True") is True assert bool_str("FALSE") is False + def fetch_git_sha(): """ Get short commit id, runnable anywhere within a git repository. """ - return subprocess.check_output(['git', - 'rev-parse', - '--short', - 'HEAD']).decode('ascii').strip() + return ( + subprocess.check_output(["git", "rev-parse", "--short", "HEAD"]).decode("ascii").strip() + ) + class Config(object): GIT_REVISION = ( |