diff --git a/modal/cli/run.py b/modal/cli/run.py index ccc7073dc..7567eb916 100644 --- a/modal/cli/run.py +++ b/modal/cli/run.py @@ -3,6 +3,7 @@ import functools import inspect import re +import shlex import sys import time from functools import partial @@ -411,4 +412,4 @@ def shell( region=region.split(",") if region else [], ) - start_shell(app, cmd=[cmd], environment_name=env, timeout=3600) + start_shell(app, cmd=shlex.split(cmd), environment_name=env, timeout=3600)