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.

Migrating to the EU

https://rz01.org/eu-migration/
285•exitnode•2h ago•197 comments

Attractive students no longer receive better results as classes moved online

https://www.sciencedirect.com/science/article/pii/S016517652200283X
76•jdthedisciple•1h ago•65 comments

POSSE – Publish on your Own Site, Syndicate Elsewhere

https://indieweb.org/POSSE
199•tosh•4h ago•47 comments

GitHub appears to be struggling with measly three nines availability

https://www.theregister.com/2026/02/10/github_outages/
106•richtr•2h ago•40 comments

PC Gamer recommends RSS readers in a 37mb article that just keeps downloading

https://stuartbreckenridge.net/2026-03-19-pc-gamer-recommends-rss-readers-in-a-37mb-article/
671•JumpCrisscross•18h ago•317 comments

General Motors Is Assisting with the Restoration of a Rare EV1

https://evinfo.net/2026/03/general-motors-is-assisting-with-the-restoration-of-an-1996-ev1/
22•betacollector64•2d ago•10 comments

Bombadil: Property-based testing for web UIs by Antithesis

https://github.com/antithesishq/bombadil
11•Klaster_1•4d ago•0 comments

Tin Can, a 'landline' for kids

https://www.businessinsider.com/tin-can-landline-kids-cellphone-cell-alternative-how-2025-9
185•tejohnso•2d ago•133 comments

The gold standard of optimization: A look under the hood of RollerCoaster Tycoon

https://larstofus.com/2026/03/22/the-gold-standard-of-optimization-a-look-under-the-hood-of-rolle...
422•mariuz•17h ago•122 comments

Walmart: ChatGPT checkout converted 3x worse than website

https://searchengineland.com/walmart-chatgpt-checkout-converted-worse-472071
159•speckx•3d ago•108 comments

Can you get root with only a cigarette lighter? (2024)

https://www.da.vidbuchanan.co.uk/blog/dram-emfi.html
104•HeliumHydride•3d ago•19 comments

Show HN: The King Wen Permutation: [52, 10, 2]

https://gzw1987-bit.github.io/iching-math/
31•gezhengwen•4h ago•15 comments

The future of version control

https://bramcohen.com/p/manyana
556•c17r•21h ago•309 comments

Reports of code's death are greatly exaggerated

https://stevekrouse.com/precision
440•stevekrouse•1d ago•334 comments

Why I love NixOS

https://www.birkey.co/2026-03-22-why-i-love-nixos.html
345•birkey•19h ago•245 comments

The way CTRL-C in Postgres CLI cancels queries is incredibly hack-y

https://neon.com/blog/ctrl-c-in-psql-gives-me-the-heebie-jeebies
84•andrenotgiant•2d ago•19 comments

Project Nomad – Knowledge That Never Goes Offline

https://www.projectnomad.us
490•jensgk•1d ago•170 comments

Jazz CRJ9 at New York on Mar 22nd 2026, collision with fire truck on runway

https://avherald.com/h?article=536bb98e
25•Shank•1h ago•11 comments

Dataframe 1.0.0.0

https://discourse.haskell.org/t/ann-dataframe-1-0-0-0/13834
48•internet_points•3h ago•4 comments

Flash-MoE: Running a 397B Parameter Model on a Laptop

https://github.com/danveloper/flash-moe
364•mft_•1d ago•116 comments

GoGoGrandparent (YC S16) is hiring Back end Engineers

https://www.ycombinator.com/companies/gogograndparent/jobs/2vbzAw8-backend-engineer
1•davidchl•9h ago

Fyn: An uv fork with new features, bug fixes, stripped telemetry

https://github.com/duriantaco/fyn
16•BiteCode_dev•20m ago•3 comments

You are not your job

https://jry.io/writing/you-are-not-your-job/
236•jryio•21h ago•265 comments

What young workers are doing to AI-proof themselves

https://www.wsj.com/economy/jobs/ai-jobs-young-people-careers-14282284
163•wallflower•18h ago•258 comments

GrapheneOS will remain usable by anyone without requiring personal information

https://grapheneos.social/@GrapheneOS/116261301913660830
464•nothrowaways•15h ago•139 comments

Ordered dithering with arbitrary or irregular colour palettes (2023)

https://matejlou.blog/2023/12/06/ordered-dithering-for-arbitrary-or-irregular-palettes/
56•surprisetalk•5d ago•9 comments

Building an FPGA 3dfx Voodoo with Modern RTL Tools

https://noquiche.fyi/voodoo
208•fayalalebrun•23h ago•45 comments

Five years of running a systems reading group at Microsoft

https://armaansood.com/posts/systems-reading-group/
175•Foe•19h ago•51 comments

MAUI Is Coming to Linux

https://avaloniaui.net/blog/maui-avalonia-preview-1
229•DeathArrow•21h ago•140 comments

More common mistakes to avoid when creating system architecture diagrams

https://www.ilograph.com/blog/posts/more-common-diagram-mistakes/
211•billyp-rva•1d ago•62 comments