chore(clean): Fix codestyle of config.py
ci/woodpecker/push/lint Pipeline was successful Details
ci/woodpecker/push/test Pipeline was successful Details

This commit is contained in:
Ferdinand Thiessen 2022-02-22 11:07:15 +01:00
parent c5db932065
commit e510c54bd8
3 changed files with 3 additions and 3 deletions

View File

@ -3,4 +3,4 @@ pipeline:
image: python:slim image: python:slim
commands: commands:
- pip install black - pip install black
- black --check --line-length 120 --target-version=py37 . - black --check --line-length 120 --target-version=py39 .

View File

@ -56,7 +56,7 @@ def configure_logger():
logger_config["handlers"]["wsgi"]["level"] = level logger_config["handlers"]["wsgi"]["level"] = level
# Read default config # Read default config
logger_config = toml.load(Path(__file__).parent /"logging.toml") logger_config = toml.load(Path(__file__).parent / "logging.toml")
if "LOGGING" in config: if "LOGGING" in config:
# Override with user config # Override with user config
update_dict(logger_config, config.get("LOGGING")) update_dict(logger_config, config.get("LOGGING"))

View File

@ -105,7 +105,7 @@ def frontend(userid, current_session):
raise Forbidden raise Forbidden
if request.method == "POST": if request.method == "POST":
if request.content_length > 1024 ** 2: if request.content_length > 1024**2:
raise BadRequest raise BadRequest
current_session.user_.set_attribute("frontend", request.get_json()) current_session.user_.set_attribute("frontend", request.get_json())
return no_content() return no_content()