Skip to content

Commit

Permalink
removed old pylint
Browse files Browse the repository at this point in the history
  • Loading branch information
sanderegg committed Nov 4, 2024
1 parent e7cc973 commit f559aac
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,18 +20,18 @@ async def docker_client() -> AsyncIterator[aiodocker.docker.Docker]:


async def swarm_get_number_nodes() -> int:
async with docker_client() as client: # pylint: disable=not-async-context-manager
async with docker_client() as client:
nodes = await client.nodes.list()
return len(nodes)


async def swarm_has_manager_nodes() -> bool:
async with docker_client() as client: # pylint: disable=not-async-context-manager
async with docker_client() as client:
nodes = await client.nodes.list(filters={"role": "manager"})
return bool(nodes)


async def swarm_has_worker_nodes() -> bool:
async with docker_client() as client: # pylint: disable=not-async-context-manager
async with docker_client() as client:
nodes = await client.nodes.list(filters={"role": "worker"})
return bool(nodes)

0 comments on commit f559aac

Please sign in to comment.