Skip to content

Commit c9a01d1

Browse files
nanotaboadaclaude
andcommitted
fix(server): annotate unused on_starting parameter as _server: Any (#2)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 58a5596 commit c9a01d1

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

gunicorn.conf.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
import multiprocessing
1010
import os
1111
from pathlib import Path
12+
from typing import Any
1213

1314
from alembic import command
1415
from alembic.config import Config
@@ -18,7 +19,7 @@
1819
worker_class: str = "uvicorn.workers.UvicornWorker"
1920

2021

21-
def on_starting(server) -> None:
22+
def on_starting(_server: Any) -> None:
2223
"""Apply Alembic migrations once before workers are spawned."""
23-
alembic_cfg = Config(str(Path(__file__).resolve().parent / "alembic.ini"))
24-
command.upgrade(alembic_cfg, "head")
24+
alembic_config = Config(str(Path(__file__).resolve().parent / "alembic.ini"))
25+
command.upgrade(alembic_config, "head")

0 commit comments

Comments
 (0)