We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 880a790 commit b3b6fffCopy full SHA for b3b6fff
1 file changed
Lib/profiling/sampling/cli.py
@@ -614,6 +614,10 @@ def _handle_attach(args):
614
615
def _handle_run(args):
616
"""Handle the 'run' command."""
617
+ # Validate script exists (only for scripts, not modules)
618
+ if not args.module and not os.path.exists(args.target):
619
+ sys.exit(f"Error: script not found: {args.target}")
620
+
621
# Check if live mode is requested
622
if args.live:
623
_handle_live_run(args)
0 commit comments