feat(cli): support studio deploy (#7394)

# Description 

Supports deploying to langsmith from langgraph studio 

Adds the following to the langgraph deploy command:
- json event output 
- non-interactive mode
This commit is contained in:
Asamu David
2026-05-06 03:20:50 +01:00
committed by GitHub
parent 86baa5d08e
commit b333d4c838
4 changed files with 641 additions and 112 deletions
+7 -1
View File
@@ -12,10 +12,11 @@ class Progress:
while True:
yield from "|/-\\"
def __init__(self, *, message="", elapsed: bool = False):
def __init__(self, *, message="", elapsed: bool = False, json_mode: bool = False):
self.message = message
self._base_message = message
self._show_elapsed = elapsed
self._json_mode = json_mode
# use this to make sure we don't kill thread when we set msg to ""
self._stop = threading.Event()
# signalled when the spinner has no text on screen
@@ -69,6 +70,9 @@ class Progress:
self._line_clear.set()
def __enter__(self) -> Callable[[str], None]:
if self._json_mode:
return lambda message: None
if sys.stdout.isatty():
self.thread = threading.Thread(target=self.spinner_task)
self.thread.start()
@@ -90,6 +94,8 @@ class Progress:
return set_message
def __exit__(self, exception, value, tb):
if self._json_mode:
return
if sys.stdout.isatty():
self.message = ""
self._stop.set()