diff --git a/pyproject.toml b/pyproject.toml index 887b3bc..d69035f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -94,16 +94,16 @@ dependencies = [ ] [tool.hatch.envs.lint.scripts] -typing = "mypy --enable-incomplete-feature=Unpack {args}" +typing = "mypy {args}" style = [ - "ruff {args:.}", + "ruff check {args:.}", "isort --check {args:.}", "black --check --diff {args:.}", ] fmt = [ "isort {args:.}", "black {args:.}", - "ruff --fix {args:.}", + "ruff check --fix {args:.}", ] all = [ "fmt", @@ -114,6 +114,8 @@ all = [ [tool.ruff] line-length = 90 extend-exclude = ["src/scripts/agent.py"] + +[tool.ruff.lint] select = [ "E", "W", "F", # flake8 (pycodestyle and pyflakes) "N", # pep8-naming diff --git a/src/appsignal/opentelemetry.py b/src/appsignal/opentelemetry.py index 69e04b2..f4afd3a 100644 --- a/src/appsignal/opentelemetry.py +++ b/src/appsignal/opentelemetry.py @@ -112,9 +112,9 @@ def start_opentelemetry(config: Config) -> None: # Configure OpenTelemetry request headers config request_headers = list_to_env_str(config.option("request_headers")) if request_headers: - os.environ[ - "OTEL_INSTRUMENTATION_HTTP_CAPTURE_HEADERS_SERVER_REQUEST" - ] = request_headers + os.environ["OTEL_INSTRUMENTATION_HTTP_CAPTURE_HEADERS_SERVER_REQUEST"] = ( + request_headers + ) opentelemetry_port = config.option("opentelemetry_port") _start_opentelemetry_tracer(opentelemetry_port)