Python Bytes

#434 Most of OpenAI’s tech stack runs on Python

17 snips
Jun 2, 2025
Discover how the PyPI test suite was made 81% faster through clever strategies like parallel execution and database isolation. Dive into the world of OpenAI's tech stack, showcasing Python's pivotal role. Learn about optimizing import performance in Python, and check out quick insights from PyCon talks. The conversation wraps up with a light-hearted take on AI's impact on programming, making for an engaging listen!
Ask episode
AI Snips
Chapters
Transcript
Episode notes
ADVICE

Speed Up Tests With Pytest-xdist

  • Use pytest-xdist to parallelize test execution across CPU cores for huge speed gains.
  • Isolate each test worker with its own database instance to avoid shared resource conflicts.
ADVICE

Faster Coverage with Python 3.12 Sysmon

  • Enable Python 3.12's sys.monitoring via coverage.py with COVERAGE_CORE=sysmon for faster coverage.
  • This reduces test runtime significantly by optimizing coverage instrumentation.
ADVICE

Optimize Pytest Discovery

  • Always specify testpaths in pytest config to optimize test discovery.
  • This simple one-line config can reduce test collection time and improve overall speed.
Get the Snipd Podcast app to discover more snips from this episode
Get the app