(base_dir: Path, patterns: Iterable[str])
| 72 | |
| 73 | |
| 74 | def find_output_artifacts(base_dir: Path, patterns: Iterable[str]) -> list[Path]: |
| 75 | found: list[Path] = [] |
| 76 | for pattern in patterns: |
| 77 | found.extend(sorted(base_dir.rglob(pattern))) |
| 78 | seen: set[str] = set() |
| 79 | unique: list[Path] = [] |
| 80 | for path in found: |
| 81 | resolved = str(path.resolve()) |
| 82 | if resolved in seen: |
| 83 | continue |
| 84 | seen.add(resolved) |
| 85 | unique.append(path.resolve()) |
| 86 | return unique |
no test coverage detected