On this page
  1. sys.remote_exec
  2. Import
  3. Signature & Overview
  4. Usage
  5. Gotchas
  6. REPL Inspect

sys.remote_exec

Prev: sys.is_stack_trampoline_active | Up: sys | Next: sys.set_asyncgen_hooks
Rel: sys.activate_stack_trampoline, sys.addaudithook, sys.audit, sys.breakpointhook
Ref: docs.python.org — sys.remote_exec
Tags: #public #python3 #stdlib #sys


Import

import sys
from sys import remote_exec

Signature & Overview

sys.remote_exec(pid, script)

Executes a file containing Python code in a given remote Python process.

Usage

import sys

# Python 3.14+ (PEP 768): schedules a diagnostic script in another Python process
assert hasattr(sys, "remote_exec")

Gotchas

REPL Inspect

from sys import remote_exec
help(remote_exec)

Linked from

Related notes