MCPcopy
hub / github.com/ray-project/ray / status

Function status

python/ray/serve/scripts.py:697–730  ·  view source on GitHub ↗
(address: str, name: Optional[str])

Source from the content-addressed store, hash-verified

695 ),
696)
697def status(address: str, name: Optional[str]):
698 warn_if_agent_address_set()
699
700 serve_details = ServeInstanceDetails(
701 **ServeSubmissionClient(address).get_serve_details()
702 )
703 status = asdict(serve_details._get_status())
704
705 # Ensure multi-line strings in app_status is dumped/printed correctly
706 if name is None:
707 print(
708 yaml.dump(
709 # Ensure exception traceback in app_status are printed correctly
710 process_dict_for_yaml_dump(status),
711 Dumper=ServeDeploySchemaDumper,
712 default_flow_style=False,
713 sort_keys=False,
714 ),
715 end="",
716 )
717 else:
718 if name not in serve_details.applications:
719 cli_logger.error(f'Application "{name}" does not exist.')
720 else:
721 print(
722 yaml.dump(
723 # Ensure exception tracebacks in app_status are printed correctly
724 process_dict_for_yaml_dump(status["applications"][name]),
725 Dumper=ServeDeploySchemaDumper,
726 default_flow_style=False,
727 sort_keys=False,
728 ),
729 end="",
730 )
731
732
733@cli.command(

Callers

nothing calls this directly

Calls 9

_get_statusMethod · 0.95
printFunction · 0.85
get_serve_detailsMethod · 0.45
dumpMethod · 0.45
errorMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…