Initializes the DockerToolExecutor.
(
self,
original_executor: ToolExecutor,
docker_manager: DockerManager,
docker_tools: list[str],
host_workspace_dir: str | None,
container_workspace_dir: str,
)
| 13 | """ |
| 14 | |
| 15 | def __init__( |
| 16 | self, |
| 17 | original_executor: ToolExecutor, |
| 18 | docker_manager: DockerManager, |
| 19 | docker_tools: list[str], |
| 20 | host_workspace_dir: str | None, |
| 21 | container_workspace_dir: str, |
| 22 | ): |
| 23 | """ |
| 24 | Initializes the DockerToolExecutor. |
| 25 | """ |
| 26 | self._original_executor = original_executor |
| 27 | self._docker_manager = docker_manager |
| 28 | self._docker_tools_set = set(docker_tools) |
| 29 | # Get path from __init__ --- |
| 30 | self._host_workspace_dir = ( |
| 31 | os.path.abspath(host_workspace_dir) if host_workspace_dir else None |
| 32 | ) |
| 33 | self._container_workspace_dir = container_workspace_dir |
| 34 | |
| 35 | def _translate_path(self, host_path: str) -> str: |
| 36 | """Robust path translation function: Translate the host path into the corresponding path within the container.""" |
nothing calls this directly
no outgoing calls
no test coverage detected