#632·petals

Should psutil be a runtime dependency?

Author: suliuzhCreated Aug 18, 2026Updated Aug 18, 2026

The production server module imports psutil at module load (src/petals/server/server.py:9-15) and uses it to determine host memory (src/petals/server/server.py:294-299).

However, psutil is now only listed under [options.extras_require]. This means a clean production installation (e.g., pip install petals) will not include it, causing the server to crash immediately on startup with an ImportError.

Proposed Fix Move psutil from the extra to the core install_requires list in setup.cfg.

Source: bigscience-workshop/petals