fixed pyservectl linter errors and formatting

This commit is contained in:
Илья Глазунов
2025-12-04 03:17:21 +03:00
parent 7662a7924a
commit 3b59994fc9
15 changed files with 87 additions and 62 deletions
+3 -2
View File
@@ -4,6 +4,7 @@ pyserve scale - Scale services
import asyncio
from pathlib import Path
from typing import Any
import click
@@ -23,7 +24,7 @@ import click
help="Don't wait for services to be ready",
)
@click.pass_obj
def scale_cmd(ctx, scales: tuple, timeout: int, no_wait: bool):
def scale_cmd(ctx: Any, scales: tuple[str, ...], timeout: int, no_wait: bool) -> None:
"""
Scale services to specified number of workers.
@@ -66,7 +67,7 @@ def scale_cmd(ctx, scales: tuple, timeout: int, no_wait: bool):
console.print("[bold]Scaling services...[/bold]")
async def do_scale():
async def do_scale() -> None:
for service, workers in scale_map.items():
current = all_services[service].workers or 1
print_info(f"Scaling {service}: {current}{workers} workers")