move straggler files and fix some important existing bugs

This commit is contained in:
Ashwin Bharambe 2024-08-05 09:24:45 -07:00
parent 5e972ece13
commit 7890921e5c
5 changed files with 303 additions and 11 deletions

View file

@ -233,9 +233,10 @@ def topological_sort(adapters: List[Adapter]) -> List[Adapter]:
def dfs(a: Adapter, visited: Set[ApiSurface], stack: List[ApiSurface]):
visited.add(a.api_surface)
for surface in a.adapter_dependencies:
if surface not in visited:
dfs(by_id[surface], visited, stack)
if not isinstance(a, PassthroughApiAdapter):
for surface in a.adapter_dependencies:
if surface not in visited:
dfs(by_id[surface], visited, stack)
stack.append(a.api_surface)