diff --git a/src/apm_cli/compilation/agents_compiler.py b/src/apm_cli/compilation/agents_compiler.py index 17fb2a27..0df0ec41 100644 --- a/src/apm_cli/compilation/agents_compiler.py +++ b/src/apm_cli/compilation/agents_compiler.py @@ -838,7 +838,7 @@ def _generate_placement_summary(self, distributed_result) -> str: for placement in distributed_result.placements: try: - rel_path = placement.agents_path.relative_to(self.base_dir.resolve()).as_posix() + rel_path = placement.agents_path.resolve().relative_to(self.base_dir.resolve()).as_posix() except ValueError: rel_path = str(placement.agents_path) lines.append(f"{rel_path}") @@ -868,7 +868,7 @@ def _generate_distributed_summary(self, distributed_result, config: CompilationC for placement in distributed_result.placements: try: - rel_path = placement.agents_path.relative_to(self.base_dir.resolve()).as_posix() + rel_path = placement.agents_path.resolve().relative_to(self.base_dir.resolve()).as_posix() except ValueError: rel_path = str(placement.agents_path) lines.append(f"- {rel_path} ({len(placement.instructions)} instructions)")