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

Comments

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

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

Multiprocessing all the way!

emmelaich•10mo ago
(2021)

Good article!

punnerud•10mo 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•10mo 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•10mo ago
How does the GIL come into play here?
punnerud•10mo 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.

Moving from GitHub to Codeberg, for lazy people

https://unterwaditzer.net/2025/codeberg.html
347•jslakro•4h ago•162 comments

My minute-by-minute response to the LiteLLM malware attack

https://futuresearch.ai/blog/litellm-attack-transcript/
95•Fibonar•1h ago•47 comments

OpenTelemetry profiles enters public alpha

https://opentelemetry.io/blog/2026/profiles-alpha/
48•tanelpoder•1h ago•5 comments

Why so many control rooms were seafoam green (2025)

https://bethmathews.substack.com/p/why-so-many-control-rooms-were-seafoam
14•Amorymeltzer•1d ago•0 comments

Show HN: Claude skill that evaluates B2B vendors by talking to their AI agents

https://github.com/salespeak-ai/buyer-eval-skill
32•ogotlieb•1h ago•0 comments

Personal Encyclopedias

https://whoami.wiki/blog/personal-encyclopedias
673•jrmyphlmn•22h ago•134 comments

Interoperability Can Save the Open Web (2023)

https://spectrum.ieee.org/doctorow-interoperability
136•janandonly•2h ago•38 comments

From zero to a RAG system: successes and failures

https://en.andros.dev/blog/aa31d744/from-zero-to-a-rag-system-successes-and-failures/
215•andros•2d ago•69 comments

My home network observes bedtime with OpenBSD and pf

https://ratfactor.com/openbsd/pf-gateway-bedtime
61•ibobev•3d ago•14 comments

HyperAgents: Self-referential self-improving agents

https://github.com/facebookresearch/hyperagents
5•andyg_blog•2d ago•0 comments

Colibri – chat platform built on the AT Protocol for communities big and small

https://colibri.social/
6•todotask2•18m ago•2 comments

End of "Chat Control": EU parliament stops mass surveillance

https://www.patrick-breyer.de/en/end-of-chat-control-eu-parliament-stops-mass-surveillance-in-vot...
336•amarcheschi•5h ago•196 comments

Running Tesla Model 3's computer on my desk using parts from crashed cars

https://bugs.xdavidhu.me/tesla/2026/03/23/running-tesla-model-3s-computer-on-my-desk-using-parts-...
788•driesdep•20h ago•271 comments

Swift 6.3

https://www.swift.org/blog/swift-6.3-released/
265•ingve•10h ago•159 comments

Light on Glass: Why do you start making a game engine?

https://analogdreamdev.substack.com/p/light-on-glass
18•atan2•3d ago•3 comments

Obsolete Sounds

https://citiesandmemory.com/obsolete-sounds/
160•benbreen•13h ago•33 comments

Building a Blog with Elixir and Phoenix

https://jola.dev/posts/building-a-blog-with-elixir-and-phoenix
8•shintoist•31m ago•0 comments

Stripe Projects: Provision and manage services from the CLI

https://projects.dev/
13•piinbinary•1h ago•4 comments

Shell Tricks That Make Life Easier (and Save Your Sanity)

https://blog.hofstede.it/shell-tricks-that-actually-make-life-easier-and-save-your-sanity/
388•zdw•17h ago•186 comments

SpaceStarCarz KoolWheelz Paper Models

https://davesdesigns.ca/dcc/html/spacestarcarz_.html
21•exvi•2d ago•4 comments

Doom entirely from DNS records

https://github.com/resumex/doom-over-dns
3•Venn1•3d ago•0 comments

Intel Announces Arc Pro B70 and Arc Pro B65 GPUs

https://www.techpowerup.com/347703/intel-announces-arc-pro-b70-and-arc-pro-b65-gpus-maxes-out-xe2...
85•throwaway270925•3h ago•35 comments

Niche Museums

https://www.niche-museums.com/
83•bookofjoe•2d ago•39 comments

AI users whose lives were wrecked by delusion

https://www.theguardian.com/lifeandstyle/2026/mar/26/ai-chatbot-users-lives-wrecked-by-delusion
107•tim333•4h ago•95 comments

Ashby (YC W19) Is Hiring Engineers Who Make Product Decisions

https://www.ashbyhq.com/careers?ashby_jid=c3c7125d-7883-4dff-a2bf-f5a55de4a364&utm_source=hn
1•abhikp•10h ago

Optimizing a lock-free ring buffer

https://david.alvarezrosa.com/posts/optimizing-a-lock-free-ring-buffer/
54•dalvrosa•2d ago•53 comments

ARC-AGI-3

https://arcprize.org/arc-agi/3
475•lairv•23h ago•305 comments

French e, è, é, ê, ë – what's the difference?

https://jakubmarian.com/french-e-e-e-e-e-whats-the-difference/
80•kerblang•2h ago•82 comments

Optimization lessons from a Minecraft structure locator

https://purplesyringa.moe/blog/optimization-lessons-from-a-minecraft-structure-locator/
48•ftk_•5d ago•6 comments

Earthquake scientists reveal how overplowing weakens soil at experimental farm

https://www.washington.edu/news/2026/03/19/earthquake-scientists-reveal-how-overplowing-weakens-s...
206•Brajeshwar•1d ago•110 comments