MCPcopy
hub / github.com/gpustack/gpustack / get_cluster

Function get_cluster

gpustack/routes/clusters.py:313–320  ·  view source on GitHub ↗
(session: SessionDep, ctx: TenantContextDep, id: int)

Source from the content-addressed store, hash-verified

311
312@router.get("/{id}", response_model=ClusterPublic, response_model_exclude_none=True)
313async def get_cluster(session: SessionDep, ctx: TenantContextDep, id: int):
314 cluster = await Cluster.one_by_id(
315 session,
316 id,
317 options=CLUSTER_LOAD_OPTIONS,
318 )
319 assert_cluster_visible(ctx, cluster, not_found_message=f"cluster {id} not found")
320 return cluster
321
322
323def create_update_check(

Callers

nothing calls this directly

Calls 2

assert_cluster_visibleFunction · 0.90
one_by_idMethod · 0.80

Tested by

no test coverage detected