Python Packaging, Local LLMs, and PyCharm's AI
WebAssembly and Python Tooling
PyToWasm
This episode explores PyToWasm, a new tool designed to compile Python into WebAssembly (Wasm).
• It focuses on achieving better performance than existing CPython Wasm implementations.
• Performance is reported to be about three times faster than typical Wasm alternatives, reaching roughly two-thirds the speed of native CPython.
• The tool is built upon Nuitka, which currently necessitates using Python 3.11.
Browsing Python Packages: Oven and PyPI Browser
The hosts discuss better ways to explore the Python packaging ecosystem beyond standard PyPI web searches:
• Oven: A highly visual, modern interface for exploring packages. It allows users to inspect the contents of wheels and source distributions directly in the browser.
• PyPI Browser: A Starlette-based open-source tool that offers similar functionality, including the ability to host your own private registry browser.
Developer Productivity
PyCharm’s Local Code Intelligence
A significant highlight is the new, local AI code completion feature in PyCharm Pro.
"It’s just nice and local and sweet."
• Unlike many coding assistants that send code to the cloud, this feature runs locally, ensuring data privacy and high speed even when offline.
• It is effective at suggesting complex boilerplate, such as Flask template rendering based on project structure.
Local LLMs with LM Studio
The hosts spotlight the integration of Llama 3 into LM Studio, enabling powerful, off-line LLM interactions for tasks like explaining complex configurations, such as Docker Compose.
Tech Industry Trends and Gotchas
Google Layoffs
The episode touches upon the concerning trend of layoffs within Google's Python, Flutter, and Dart teams, noting the disconnect between high corporate profitability and downsizing.
Python Gotcha: String Stripping
A public service announcement regarding lstrip and rstrip:
• Users often mistake these for substring removal tools.
• They actually operate on a set of characters.
• For safe substring removal, developers should use removeprefix and removesuffix.