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•12mo ago

Comments

quentinp•12mo 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•12mo ago
Page didnt load for me.

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

Multiprocessing all the way!

emmelaich•12mo ago
(2021)

Good article!

punnerud•12mo 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•12mo 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•12mo ago
How does the GIL come into play here?
punnerud•12mo 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 map that keeps Burning Man honest

https://www.not-ship.com/burning-man-moop/
291•speckx•3h ago•112 comments

AlphaEvolve: Gemini-powered coding agent scaling impact across fields

https://deepmind.google/blog/alphaevolve-impact/
109•berlianta•2h ago•30 comments

Child marriages plunged when girls stayed in school in Nigeria

https://www.nature.com/articles/d41586-026-00796-2
167•surprisetalk•3h ago•98 comments

The Self-Cancelling Subscription

https://predr.ag/blog/the-self-cancelling-subscription/
63•surprisetalk•2h ago•27 comments

Agents need control flow, not more prompts

https://bsuh.bearblog.dev/agents-need-control-flow/
9•bsuh•29m ago•3 comments

RaTeX: KaTeX-compatible LaTeX rendering engine in pure Rust

https://ratex.lites.dev/
107•atilimcetin•3d ago•58 comments

PySimpleGUI 6

https://github.com/PySimpleGUI/PySimpleGUI
21•geophph•1d ago•3 comments

Chrome removes claim of On-device Al not sending data to Google Servers

https://old.reddit.com/r/chrome/comments/1t5qayz/chrome_removes_claim_of_ondevice_al_not_sending/
64•newsoftheday•1h ago•7 comments

Motherboard sales are now collapsing amid unprecedented shortages fueled by AI

https://www.tomshardware.com/pc-components/motherboards/motherboard-sales-collapse-by-more-than-2...
90•speckx•1h ago•50 comments

MPEG-2 Transport Stream Packaging for Media over QUIC Transport

https://www.ietf.org/archive/id/draft-gregoire-moq-msfts-00.html
23•mondainx•2h ago•3 comments

Indian matchbox labels as a visual archive

https://www.itsnicethat.com/features/the-view-from-mumbai-matchbook-graphic-design-130426
114•sahar_builds•3d ago•27 comments

OpenBSD Stories: The closest thing to cute kittens (OpenBSD/zaurus)

http://miod.online.fr/software/openbsd/stories/zaurus1.html
11•zdw•21h ago•2 comments

Speedup in Lattice Boltzmann Cylinder Flow

https://github.com/alikamp/Parks-KPBM-Scaling
33•kauai1•2d ago•3 comments

SQLite Is a Library of Congress Recommended Storage Format

https://sqlite.org/locrsf.html
508•whatisabcdefgh•19h ago•159 comments

Boris Cherny: TI-83 Plus Basic Programming Tutorial (2004)

https://www.ticalc.org/programming/columns/83plus-bas/cherny/
142•suoken•2d ago•64 comments

GovernGPT (YC W24) Is Hiring Engineers to Build Thinking Systems in Montreal

https://www.ycombinator.com/companies/governgpt/jobs/hRyltS0-backend-engineer-thinking-systems
1•owalerys•5h ago

Appearing productive in the workplace

https://nooneshappy.com/article/appearing-productive-in-the-workplace/
1456•diebillionaires•1d ago•592 comments

Agent-harness-kit scaffolding for multi-agent workflows (MCP, provider-agnostic)

https://ahk.cardor.dev
57•enmanuelmag•6h ago•17 comments

DeepSeek 4 Flash local inference engine for Metal

https://github.com/antirez/ds4
12•tamnd•1h ago•2 comments

Diskless Linux boot using ZFS, iSCSI and PXE

https://aniket.foo/posts/20260505-netboot/
165•stereo-highway•13h ago•89 comments

Vibe coding and agentic engineering are getting closer than I'd like

https://simonwillison.net/2026/May/6/vibe-coding-and-agentic-engineering/
718•e12e•1d ago•809 comments

Valve releases Steam Controller CAD files under Creative Commons license

https://www.digitalfoundry.net/news/2026/05/valve-releases-steam-controller-cad-files-under-creat...
1651•haunter•1d ago•553 comments

RSS feeds send me more traffic than Google

https://shkspr.mobi/blog/2026/05/rss-feeds-send-me-more-traffic-than-google/
222•SpyCoder77•16h ago•49 comments

SingleRide: Longest route on NYC Subway without visiting the same station twice

https://singleride.nyc/
77•TMWNN•1d ago•41 comments

Chevrolet Performance eCrate package (400v/200hp)

https://www.chevrolet.com/performance-parts/crate-engines/ecrate
133•mindcrime•2d ago•110 comments

The mechanical latching memory of an adhesive tape

https://iopscience.iop.org/article/10.1088/1367-2630/ae4acc
20•gnabgib•1d ago•10 comments

ProgramBench: Can Language Models Rebuild Programs from Scratch?

https://arxiv.org/abs/2605.03546
110•jonbaer•13h ago•60 comments

Permacomputing Principles

https://permacomputing.net/principles/
225•andsoitis•14h ago•151 comments

I switched from Mac to a Lenovo Chromebook, and you can too

https://blog.johnozbay.com/i-left-apples-ecosystem-for-a-lenovo-chromebook-and-you-can-too.html
46•speckx•1h ago•54 comments

LinkedIn profile visitor lists belong to the people, says Noyb

https://www.theregister.com/offbeat/2026/05/05/noyb-cries-foul-on-linkedin-withholding-profile-vi...
169•robin_reala•6h ago•92 comments