Skip to content

Commit 7d92fc5

Browse files
committed
fix: make flow name retrieval efficient
1 parent 7fef101 commit 7d92fc5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

python/cocoindex/cli.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
from rich.console import Console
55

66
from . import flow, lib
7+
from .flow import flow_names
78
from .setup import sync_setup, drop_setup, flow_names_with_setup, apply_setup_changes
89
from .runtime import execution_context
910

@@ -21,7 +22,7 @@ def ls(show_all: bool):
2122
"""
2223
List all flows.
2324
"""
24-
current_flow_names = [fl.name for fl in flow.flows()]
25+
current_flow_names = flow_names()
2526
persisted_flow_names = flow_names_with_setup()
2627
remaining_persisted_flow_names = set(persisted_flow_names)
2728

0 commit comments

Comments
 (0)