Commits
Click on a commit to change the comparison rangeFix type errors by making fork reset methods public
Remove underscore prefix from reset_for_fork methods to avoid
reportPrivateUsage errors when calling from module-level fork handlers.
Verified with: uv run pyright -p pyrightconfig-ci.json --level error Replace smoke tests with proper regression test for multiprocessing deadlock
Moved the test from internal concurrency tests to testing utilities where it
belongs, and replaced the useless smoke tests with a real test that reproduces
the actual issue: using multiprocessing.Process() after prefect_test_harness().
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com> Use os._exit(0) in multiprocessing worker to bypass Python cleanup
On Linux with fork(), the child process inherits Prefect's logging and event
state. When the worker function returns normally, Python's cleanup tries to
flush logs/close connections, which can fail since those resources are in an
inconsistent state after fork. Using os._exit(0) bypasses cleanup entirely.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com> Use os._exit(0) to avoid Python cleanup in forked child process
On Linux with fork(), the child process inherits Prefect's logging/event
state. Normal exit (return or sys.exit) triggers Python cleanup that fails
with this inherited state, causing exitcode=1. os._exit() bypasses cleanup
and is documented for use "in the child process after os.fork()".
Despite the underscore prefix, this is the intended API for this scenario.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>