Python Trending Weekly
ISSUE 62

Trying Out Free-Threaded Python

2024-07-27 Season 3

TL;DR

Free-threaded Python gets a hands-on spin on macOS, PEP-751 proposes a lock-file format for reproducible installs, and Python dataframes query 1TB of data on a laptop.

Articles 12 Projects 12
🦄

Articles & Tutorials

× 12
01 Trying out free-threaded Python on macOS til.simonwillison.net

We shared free-threaded-compatibility in our last issue, and the author also discovered this project, so he installed it to try it out. Using CPU-intensive tasks for testing, he achieved extremely high CPU utilization and performance improvements.

02 PEP-751 – A file format to list Python dependencies for installation reproducibility peps.python.org

A new PEP draft created this week, serving as a replacement for the rejected PEP-665. It aims to define a standard file format for managing Python dependencies. The community already has solutions like pip freeze, pip-tools, Poetry, and PDM, but this proposal attempts to establish an official standard.

03 Beyond Hypermodern: Python is easy now rdrn.me

The author shares their project template for Python dependency/environment management and related tooling, with Rye/Ruff as core tools, covering project setup, linting, type checking, testing, documentation, CI/CD, and Monorepo management configurations. (Note: The author's series of articles about Python project management from 4 years ago)

04 Implementing Instant Search with Flask and HTMX python.plainenglish.io

Instant search refers to displaying search results immediately as users type their search queries, without waiting for page reloads, providing a better user experience. This tutorial implements simple instant search functionality using Flask and HTMX.

05 Streamlit 101: The fundamentals of a Python data app blog.streamlit.io

Streamlit enables data scientists to easily build interactive data applications. This is an official beginner's tutorial that introduces Streamlit's fundamentals and usage methods, including 5 practical examples.

06 Creating a CSV to Graph Generator App Using ToolJet and Python Libraries dev.to

ToolJet is an open-source low-code platform with over 28K GitHub stars, supporting both JS and Python code execution. This tutorial demonstrates how to use it to design user interfaces, integrate Python code, and generate various chart formats from CSV files.

Creating a CSV to Graph Generator App Using ToolJet and Python Libraries
07 Fast(er)API: Optimizing Processing Time fabridamicelli.github.io

The article shares some simple tricks to make FastAPI + Pydantic-based REST APIs run faster.

08 How To Convert A Python Script Into A Web App, A Product Others Can Use pybit.es

This tutorial shares a complete Python full-stack project that supports uploading and merging multiple PDF files, with login and authentication features.

09 Python Resource Management and Generators samgeo.codes

The article explains how to ensure proper resource cleanup and release when using Python generators and async generators. Methods covered include inline generator calls, explicit cleanup with del statements or close methods, and context manager cleanup.

10 Querying 1TB on a laptop with Python dataframes ibis-project.org

When using Pandas to process large datasets, memory issues can easily arise. The author tested Pandas, Polars, and Ibis (with DuckDB and DataFusion backends) on 1TB of data, demonstrating Ibis's huge advantages when handling large datasets.

11 A Python Epoch Timestamp Timezone Trap nerderati.com

When handling datetime in Python, timezone issues need attention, especially when converting epoch timestamps to datetime objects. It's recommended to use datetime.utcnow() instead of datetime.now() to avoid dependency on system default timezone configurations.

12 10 Alternatives to Selenium in 2024 cnblogs.com

Selenium is a widely-used open-source web automation testing tool. This article introduces 10 alternative tools and briefly covers their pros and cons.

🐿️

Projects & Resources

× 12
01 whenever: Modern datetime library for Python, written in Rust github.com

A type-safe Python datetime library with daylight saving time support, developed in Rust. Features high performance and supports the latest experimental GIL-free version.

whenever: Modern datetime library for Python, written in Rust
02 maelstrom: a fast Rust and Python test runner that runs every test in its own container github.com

Run tests in local isolated containers or distributed clusters, with each test running in a lightweight container to avoid interference from other tests and environments. Currently Linux-only.

03 wat: Deep inspection of Python objects github.com

Inspect a Python object's type, formatted values, variables, methods, parent types, signatures, documentation, and even source code at runtime.

04 neuml/txtai: All-in-one open-source embeddings database for semantic search, LLM orchestration and language model workflows github.com

An all-in-one embeddings database that combines vector indexing, graph networks, and relational databases. Supports vector search, topic modeling, retrieval-augmented generation (RAG), and more using SQL. (8.1K stars)

05 PraisonAI: combines AutoGen and CrewAI or similar frameworks into a low-code solution github.com

A low-code, centralized framework designed to simplify the creation and orchestration of multi-agent systems for various LLM applications. Supports automatic AI agent creation, chat with entire codebases, and multiple user interfaces. (1.8K stars)

06 pgmanage: Web tool for database management github.com

A web-based database client supporting PostgreSQL, SQLite, MySQL, MariaDB, Oracle, and more. Features visual database performance metrics, PostgreSQL server configuration management, backup functionality, and more.

pgmanage: Web tool for database management
07 pygamelib: A small python library for console game development github.com

Primarily aimed at children/beginners, using command-line terminals as the development environment for rapid 2D game development. Cross-platform, no graphics card dependency, sparking imagination and creativity.

08 composio: equips agents with well-crafted tools empowering them to tackle complex tasks github.com

Integrate high-quality tools for AI agents with just one line of code. Supports 100+ tools and large models, 6 different authentication protocols, and pluggable design. (4K stars)

09 Cradle: The Cradle framework is a first attempt at General Computer Control (GCC) github.com

Uses AI to read screenshots as input and control mouse and keyboard operations, completing complex computer tasks like humans do - gaming, web browsing, sending emails, using office software, and more. (1.4K stars)

10 lonboard: A Python library for fast, interactive geospatial vector data visualization in Jupyter github.com

Built on cutting-edge technologies like GeoArrow and GeoParquet, combined with GPU-based map rendering, enabling visualization of large geospatial datasets through simple interface interactions.

11 opencanary: Modular and decentralised honeypot github.com

A multi-protocol network honeypot developed in Python with extremely low resource requirements, deployable on Raspberry Pi. Simulates a series of network-accessible services and sends alerts through multiple channels when potential threats are detected. (2.2K stars)

12 amphi-etl: Low-code ETL for structured and unstructured data github.com

An ETL tool for the AI era that accelerates data pipeline development. Generates native Python code using libraries like pandas, DuckDB, and LangChain. Supports self-hosting.

amphi-etl: Low-code ETL for structured and unstructured data
ESC
↑↓ select · ↵ open175 issues