type hint
This commit is contained in:
@@ -18,7 +18,7 @@ def manage_containers(project: str, services: list[str]):
|
||||
for c in client.containers.list()
|
||||
if c.labels['com.docker.compose.project'] == project
|
||||
)
|
||||
service_dict = {
|
||||
service_dict: dict[str, Container] = {
|
||||
c.labels['com.docker.compose.service']: c for c in project_containers
|
||||
}
|
||||
containers: list[Container] = [service_dict[s] for s in services]
|
||||
|
||||
Reference in New Issue
Block a user