Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
scx1332 committed Oct 12, 2023
1 parent fe4874d commit e719441
Showing 1 changed file with 20 additions and 20 deletions.
40 changes: 20 additions & 20 deletions goth/runner/probe/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,11 +110,11 @@ class Probe(abc.ABC):
"""Config object used for setting up the Yagna node for this probe."""

def __init__(
self,
runner: "Runner",
client: DockerClient,
config: YagnaContainerConfig,
log_config: LogConfig,
self,
runner: "Runner",
client: DockerClient,
config: YagnaContainerConfig,
log_config: LogConfig,
):
self.runner = runner
self._agents = OrderedDict()
Expand Down Expand Up @@ -393,10 +393,10 @@ def get_agent_env_vars(self, expand_path: bool = True) -> Dict[str, str]:

@contextlib.asynccontextmanager
async def run_command_on_host(
self,
command: str,
env: Optional[Mapping[str, str]] = None,
command_timeout: float = 300,
self,
command: str,
env: Optional[Mapping[str, str]] = None,
command_timeout: float = 300,
) -> AsyncIterator[Tuple[asyncio.Task, PatternMatchingEventMonitor, process.ProcessMonitor]]:
"""Run `command` on host in given `env` and with optional `timeout`.
Expand Down Expand Up @@ -464,10 +464,10 @@ async def run_command_on_host(

@contextlib.contextmanager
def create_probe(
runner: "Runner",
docker_client: DockerClient,
config: YagnaContainerConfig,
log_config: LogConfig,
runner: "Runner",
docker_client: DockerClient,
config: YagnaContainerConfig,
log_config: LogConfig,
) -> Iterator[Probe]:
"""Implement a ContextManager protocol for creating and removing probes."""

Expand Down Expand Up @@ -519,13 +519,13 @@ class ProviderProbe(MarketApiMixin, PaymentApiMixin, Probe):
This field is added for convenience to make getting this agent instance easier."""

def __init__(
self,
runner: "Runner",
client: DockerClient,
config: YagnaContainerConfig,
log_config: LogConfig,
agent_preset: Optional[str] = None,
subnet: str = DEFAULT_SUBNET,
self,
runner: "Runner",
client: DockerClient,
config: YagnaContainerConfig,
log_config: LogConfig,
agent_preset: Optional[str] = None,
subnet: str = DEFAULT_SUBNET,
):
super().__init__(runner, client, config, log_config)
self.provider_agent = ProviderAgentComponent(self, subnet, agent_preset)
Expand Down

0 comments on commit e719441

Please sign in to comment.