frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

How async/await works in Python (2021)

https://tenthousandmeters.com/blog/python-behind-the-scenes-12-how-asyncawait-works-in-python/
61•sebg•8mo ago

Comments

quentinp•8mo ago
While it stays at the Python level, https://github.com/AndreLouisCaron/a-tale-of-event-loops really helped me to understand how asyncio and Trio are implemented. I had no idea how sleeps worked before reading that post.
incomingpain•8mo ago
Page didnt load for me.

https://realpython.com/async-io-python/

Multiprocessing all the way!

emmelaich•8mo ago
(2021)

Good article!

punnerud•8mo ago
A more simplified version:

Synchronous code is like a single-lane road where cars (tasks) must travel one after another in perfect sequence. If one car stops for gas (waiting for I/O), every car behind it must stop too. While orderly and predictable, this creates massive traffic jams as tasks wait unnecessarily for others to complete before they can proceed.

Pure asynchronous code (with callbacks) is like dispatching multiple cars onto independent routes with no coordination. Cars move freely without waiting for each other, but they arrive at unpredictable times and following their progress becomes chaotic. It's efficient but creates a complex tangle of paths that becomes hard to maintain.

Async/await combines the best of both approaches with a multi-lane highway system. Cars follow clear, synchronous-looking routes (making code readable), but only wait at strategic "await" exit ramps when truly necessary. When a car needs data, it signals with "await", pulls off the highway temporarily, and other cars continue flowing past. Once its operation completes, it merges back into traffic and continues. This gives you the logical simplicity of synchronous code with the performance benefits of asynchronous execution - cars only wait at crossroads when they must, maximizing throughput while maintaining order.

The genius of async/await is that it lets developers write code that looks sequential while the runtime handles all the complex traffic management under the hood.

explodes•8mo ago
Excellent write up. I appreciate the level of details here showing the history from the days of old, before async/await were even keywords.
bilsbie•8mo ago
How does the GIL come into play here?
punnerud•8mo ago
GIL is like a "red-cap" on the head for the CPU-core running the task, so you would not be able to run true Async without GIL. Have to hand the "red-cap" back, for the next task.

Instead of using a global lock ("red-cap"), Python objects have introduced a specialized reference counting system that distinguishes between "local" references (owned by a single thread) and "shared" references (accessed by multiple threads).

In that way enabling to remove GIL in the long run, now starting with making it optional.

The Codex App

https://openai.com/index/introducing-the-codex-app/
369•meetpateltech•3h ago•231 comments

Ask HN: Who is hiring? (February 2026)

214•whoishiring•5h ago•261 comments

Mattermost say they will not clarify what license the project is under

https://github.com/mattermost/mattermost/issues/8886
118•MallocVoidstar•1h ago•82 comments

Hacking Moltbook

https://www.wiz.io/blog/exposed-moltbook-database-reveals-millions-of-api-keys
163•galnagli•5h ago•111 comments

Ownership of open source flashcard app Anki transferred to for-profit AnkiHub

https://forums.ankiweb.net/t/ankis-growing-up/68610
14•trms•1h ago•2 comments

xAI Joins SpaceX

https://x.ai/news/xai-joins-spacex
4•beklein•2m ago•0 comments

The largest number representable in 64 bits

https://tromp.github.io/blog/2026/01/28/largest-number-revised
48•tromp•3h ago•36 comments

Advancing AI Benchmarking with Game Arena

https://blog.google/innovation-and-ai/models-and-research/google-deepmind/kaggle-game-arena-updates/
73•salkahfi•4h ago•37 comments

Nano-vLLM: How a vLLM-style inference engine works

https://neutree.ai/blog/nano-vllm-part-1
193•yz-yu•9h ago•24 comments

4x faster network file sync with rclone (vs rsync) (2025)

https://www.jeffgeerling.com/blog/2025/4x-faster-network-file-sync-rclone-vs-rsync/
199•indigodaddy•3d ago•98 comments

Todd C. Miller – Sudo maintainer for over 30 years

https://www.millert.dev/
223•wodniok•4h ago•128 comments

Ask HN: Who wants to be hired? (February 2026)

76•whoishiring•5h ago•175 comments

Geologists may have solved mystery of Green River's 'uphill' route

https://phys.org/news/2026-01-geologists-mystery-green-river-uphill.html
123•defrost•8h ago•29 comments

Stelvio: Ship Python to AWS

https://github.com/stelviodev/stelvio
13•todsacerdoti•1h ago•19 comments

On being sane in insane places (1973) [pdf]

https://www.weber.edu/wsuimages/psychology/FacultySites/Horvat/OnBeingSaneInInsanePlaces.PDF
54•dbgrman•4h ago•31 comments

EPA Advances Farmers' Right to Repair

https://www.epa.gov/newsreleases/epa-advances-farmers-right-repair-their-own-equipment-saving-rep...
130•bilsbie•3h ago•46 comments

General Graboids: Worms and Remote Code Execution in Command and Conquer

https://www.atredis.com/blog/2026/1/26/generals
13•speckx•6d ago•1 comments

Why software stocks are getting pummelled

https://www.economist.com/business/2026/02/01/why-software-stocks-are-getting-pummelled
84•petethomas•17h ago•125 comments

Pretty soon, heat pumps will be able to store and distribute heat as needed

https://www.sintef.no/en/latest-news/2026/pretty-soon-heat-pumps-will-be-able-to-store-and-distri...
98•PaulHoule•1d ago•83 comments

Nvidia shares are down after report that its OpenAI investment stalled

https://www.cnbc.com/2026/02/02/nvidia-stock-price-openai-funding.html
34•greatgib•1h ago•3 comments

Zig Libc

https://ziglang.org/devlog/2026/#2026-01-31
37•ingve•4h ago•4 comments

Europe just started building a 'kill switch' for U.S. tech

https://www.morningstar.com/news/marketwatch/2026020252/europe-just-started-building-a-kill-switc...
21•mooreds•1h ago•3 comments

IsoCoaster – Theme Park Builder

https://iso-coaster.com/
77•duck•3d ago•19 comments

TileIR Internals

https://maknee.github.io/blog/2026/NVIDIA-TileIR-Internals-from-CuTile-to-MLIR-LLVM-to-SASS/
4•vimarsh6739•3d ago•0 comments

Show HN: Adboost – A browser extension that adds ads to every webpage

https://github.com/surprisetalk/AdBoost
72•surprisetalk•8h ago•93 comments

My fast zero-allocation webserver using OxCaml

https://anil.recoil.org/notes/oxcaml-httpz
127•noelwelsh•11h ago•43 comments

Tomo: A statically typed, imperative language that cross-compiles to C [video]

https://www.youtube.com/watch?v=-vGE0I8RPcc
31•evakhoury•4d ago•11 comments

UK government launches fuel forecourt price API

https://www.gov.uk/guidance/access-the-latest-fuel-prices-and-forecourt-data-via-api-or-email
65•Technolithic•8h ago•83 comments

Show HN: PolliticalScience – Anonymous daily polls with 24-hour windows

https://polliticalscience.vote/
20•ps2026•4h ago•26 comments

Waymo seeking about $16B near $110B valuation

https://www.bloomberg.com/news/articles/2026-01-31/waymo-seeking-about-16-billion-near-110-billio...
165•JumpCrisscross•6h ago•227 comments