Revert "clean up"

This reverts commit bc4ac2ceb4.
This commit is contained in:
Xi Yan 2024-09-21 12:42:08 -07:00
parent 50d95a668b
commit 515bec300c
4 changed files with 36 additions and 28 deletions

View file

@ -389,7 +389,12 @@ def main(yaml_config: str, port: int = 5000, disable_ipv6: bool = False):
cprint(f"StackRunConfig: {config}", "blue")
app = FastAPI()
impls, specs = asyncio.run(resolve_impls_with_routing(config))
# check if routing table exists
if config.provider_routing_table is not None:
impls, specs = asyncio.run(resolve_impls_with_routing(config))
else:
# keeping this for backwards compatibility
impls, specs = asyncio.run(resolve_impls(config.provider_map))
if Api.telemetry in impls:
setup_logger(impls[Api.telemetry])