mirror of
https://github.com/langchain-ai/langgraph.git
synced 2026-09-05 17:27:47 +02:00
chore: validate
This commit is contained in:
@@ -817,6 +817,23 @@ def dev(
|
||||
)
|
||||
|
||||
|
||||
# ---------------------------------------------------------------------------
|
||||
# validate command
|
||||
# ---------------------------------------------------------------------------
|
||||
|
||||
|
||||
@OPT_CONFIG
|
||||
@cli.command(help="✅ Validate the LangGraph configuration file.")
|
||||
@log_command
|
||||
def validate(config: pathlib.Path):
|
||||
config_json = langgraph_cli.config.validate_config_file(config)
|
||||
num_graphs = len(config_json.get("graphs", {}))
|
||||
click.echo(
|
||||
f"Configuration file {config} is valid. "
|
||||
f"({num_graphs} graph{'s' if num_graphs != 1 else ''} found)"
|
||||
)
|
||||
|
||||
|
||||
# ---------------------------------------------------------------------------
|
||||
# new command
|
||||
# ---------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user