Python BytesMichael Kennedy and Calvin Hendryx-ParkerAll episodes
#507 Something about security
Topics covered in this episode:
- AI agents model CPython in Lean and produce 415 bug reports
- Amazon Athena powered by DuckDB, now available in preview
- Citry
- PSF announces a Security Roadmap
- Extras
- Joke
Michael #1: AI agents model CPython in Lean and produce 415 bug reports
David Andrews and Chao Zhang used AI agents to translate CPython 3.15.2 functions into Lean and check proofs about their behavior. Their November 13 post reports 4,067 accepted functions, 614,384 lines of Lean, and 415 bug reports, including about 55 involving crashes or memory corruption.
- Coverage is 14.3% of functions worth checking, not a fully verified interpreter. Multithreading is out of scope.
- Each model faces at least 50,000 differential test inputs, proofs, and review by a second agent before acceptance.
- A valid Lean proof can still describe the wrong model. Early reviews rejected weak properties that even broken functions could satisfy.
- 415 reports does not mean 415 newly confirmed upstream bugs: some were already known, and remaining reports are being submitted.
- I asked what involvement the core team and CPython had with Project Glasswing. I think it was zero. It should be far more involved. Open someone reaches out to OSS Scanner.
Calvin #2: Amazon Athena powered by DuckDB, now available in preview
- Remember when AWS bought DuckLabs? Here's what they built.
- Announced Dec 1, 2026 at re:Invent and in preview in 5 regions: us-east-1, us-east-2, us-west-2, eu-west-1 and ap-northeast-1.
- Athena's serverless query service now runs on DuckDB and splits a single query across many workers when the data outgrows one machine.
- AWS claims queries are up to 2x faster and up to 50% cheaper than Athena engine v3 on large datasets.
- Queries use DuckDB's SQL dialect and run against your existing Glue Data Catalog tables, so there's nothing to redefine and no data to move.
- Results can come back as Apache Arrow through a new streaming API and an ADBC driver, landing in data science tools with no conversion step.
- A new open-source Athena extension for DuckDB lets you prototype a query in local DuckDB and then run the same SQL on Athena at scale.
- Supports Apache Iceberg v3 and Parquet tables. To turn it on, create a workgroup or switch an existing one to DuckDB.
- Related: a separate Redshift extension for DuckDB (Apache 2.0, DuckDB v2.0.1) lets you query Redshift from a local DuckDB session and join the results with local Parquet or CSV files.
Michael #3: Citry
Citry's first stable release puts HTML templates, CSS, browser behavior and Python event handlers in one component class. Built by django-components maintainer Juro Oravec, it aims to give Python web developers Vue-style tooling without maintaining a separate frontend project. Clicks can call Python and replace the component's HTML.
- The editor catches template typos and wrong component inputs before someone opens the page. Run the checks in CI with citry check; useful feedback for humans and coding agents alike.
- Uses Vue for browser behavior, rather than eliminating JavaScript. Works with Django, FastAPI, Flask and other ASGI/WSGI apps.
- Author's error benchmark reports 56 of 61