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.

MapLibre Tile: a modern and efficient vector tile format

https://maplibre.org/news/2026-01-23-mlt-release/
156•todsacerdoti•3h ago•32 comments

Vibe Coding Kills Open Source

https://arxiv.org/abs/2601.15494
24•kgwgk•48m ago•1 comments

Transfering Files with gRPC

https://kreya.app/blog/transfering-files-with-grpc/
12•CommonGuy•32m ago•0 comments

The Holy Grail of Linux Binary Compatibility: Musl and Dlopen

https://github.com/quaadgras/graphics.gd/discussions/242
101•Splizard•6h ago•78 comments

Things I've learned in my 10 years as an engineering manager

https://www.jampa.dev/p/lessons-learned-after-10-years-as
268•jampa•4d ago•49 comments

The browser is the sandbox

https://simonwillison.net/2026/Jan/25/the-browser-is-the-sandbox/
211•enos_feedler•8h ago•125 comments

First, make me care

https://gwern.net/blog/2026/make-me-care
658•andsoitis•18h ago•202 comments

Text Is King

https://www.experimental-history.com/p/text-is-king
44•zdw•5d ago•25 comments

Scientists identify brain waves that define the limits of 'you'

https://www.sciencealert.com/scientists-identify-brain-waves-that-define-the-limits-of-you
232•mikhael•13h ago•59 comments

A macOS app that blurs your screen when you slouch

https://github.com/tldev/posturr
626•dnw•22h ago•204 comments

Wind Chime Length Calculator (2022)

https://www.snyderfamily.com/chimecalcs/
15•hyperific•5d ago•6 comments

San Francisco Graffiti

https://walzr.com/sf-graffiti
43•walz•3h ago•31 comments

The future of software engineering is SRE

https://swizec.com/blog/the-future-of-software-engineering-is-sre/
169•Swizec•15h ago•74 comments

Emissary, a fast open-source Java messaging library

https://github.com/joel-jeremy/emissary
21•jeyjeyemem•3d ago•9 comments

A static site generator written in POSIX shell

https://aashvik.com/posts/shell-ssg/
48•todsacerdoti•6d ago•27 comments

LED lighting undermines visual performance unless supplemented by wider spectra

https://www.nature.com/articles/s41598-026-35389-6
125•bookofjoe•16h ago•109 comments

Clinic-in-the-Loop

https://www.asimov.press/p/clinic-loop
7•surprisetalk•4d ago•0 comments

Using PostgreSQL as a Dead Letter Queue for Event-Driven Systems

https://www.diljitpr.net/blog-post-postgresql-dlq
229•tanelpoder•21h ago•72 comments

Video Games as Art

https://gwern.net/video-game-art
83•andsoitis•11h ago•51 comments

Show HN: Only 1 LLM can fly a drone

https://github.com/kxzk/snapbench
5•beigebrucewayne•2h ago•0 comments

Running the Stupid Cricut Software on Linux

https://arthur.pizza/2025/12/running-stupid-cricut-software-under-linux/
33•starkparker•9h ago•4 comments

I was right about ATProto key management

https://notes.nora.codes/atproto-again/
159•todsacerdoti•18h ago•148 comments

Guix for Development

https://dthompson.us/posts/guix-for-development.html
107•clircle•6d ago•44 comments

Water 'Bankruptcy' Era Has Begun for Billions, Scientists Say

https://www.bloomberg.com/news/articles/2026-01-20/water-bankruptcy-era-has-begun-for-billions-sc...
5•ciconia•52m ago•1 comments

Case study: Creative math – How AI fakes proofs

https://tomaszmachnik.pl/case-study-math-en.html
105•musculus•15h ago•71 comments

Compiling models to megakernels

https://blog.luminal.com/p/compiling-models-to-megakernels
29•jafioti•1d ago•15 comments

Show HN: An interactive map of US lighthouses and navigational aids

https://www.lighthouses.app/
83•idd2•19h ago•19 comments

Clawdbot - open source personal AI assistant

https://github.com/clawdbot/clawdbot
291•KuzeyAbi•13h ago•186 comments

The Science of Fermentation [audio]

https://www.bbc.co.uk/programmes/m002pqg6
58•fallinditch•2d ago•18 comments

SFPark: Interactive map of SF parking regulations

https://hugues.betakappaphi.com/2026/01/21/sfpark/
11•__hugues•3d ago•5 comments