frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

If You Quit Social Media, Will You Read More Books?

https://www.newyorker.com/news/fault-lines/if-you-quit-social-media-will-you-read-more-books
22•pseudolus•1h ago•15 comments

Size of Life

https://neal.fun/size-of-life/
2106•eatonphil•20h ago•230 comments

A "Frozen" Dictionary for Python

https://lwn.net/SubscriberLink/1047238/25c270b077849dc0/
36•jwilk•2h ago•10 comments

The Cost of a Closure in C

https://thephd.dev/the-cost-of-a-closure-in-c-c2y
87•ingve•4h ago•24 comments

Getting a Gemini API key is an exercise in frustration

https://ankursethi.com/blog/gemini-api-key-frustration/
587•speckx•15h ago•232 comments

Patterns.dev

https://www.patterns.dev/
330•handfuloflight•10h ago•77 comments

Australia begins enforcing world-first teen social media ban

https://www.reuters.com/legal/litigation/australia-social-media-ban-takes-effect-world-first-2025...
804•chirau•1d ago•1230 comments

Why Startups Die

https://www.techfounderstack.com/p/why-startups-die
30•makle•3d ago•16 comments

Booting Linux in QEMU and Writing PID 1 in Go to Illustrate Kernel as Program

https://serversfor.dev/linux-inside-out/the-linux-kernel-is-just-a-program/
132•birdculture•6d ago•35 comments

How the Brain Parses Language

https://www.quantamagazine.org/the-polyglot-neuroscientist-resolving-how-the-brain-parses-languag...
36•mylifeandtimes•2d ago•11 comments

Auto-grading decade-old Hacker News discussions with hindsight

https://karpathy.bearblog.dev/auto-grade-hn/
463•__rito__•18h ago•208 comments

Python Workers redux: fast cold starts, packages, and a uv-first workflow

https://blog.cloudflare.com/python-workers-advancements/
71•dom96•2d ago•20 comments

Go's escape analysis and why my function return worked

https://bonniesimon.in/blog/go-escape-analysis
16•bonniesimon•6d ago•9 comments

Helldivers 2 on-disk size 85% reduction

https://store.steampowered.com/news/app/553850/view/491583942944621371
41•SergeAx•1w ago•27 comments

How Google Maps allocates survival across London's restaurants

https://laurenleek.substack.com/p/how-google-maps-quietly-allocates
291•justincormack•2d ago•143 comments

VCMI: An open-source engine for Heroes III

https://vcmi.eu/
121•eamag•4d ago•15 comments

Super Mario 64 for the PS1

https://github.com/malucard/sm64-psx
243•LaserDiscMan•17h ago•93 comments

Rubio stages font coup: Times New Roman ousts Calibri

https://www.reuters.com/world/us/rubio-stages-font-coup-times-new-roman-ousts-calibri-2025-12-09/
298•italophil•1d ago•500 comments

Incomplete list of mistakes in the design of CSS

https://wiki.csswg.org/ideas/mistakes
128•OuterVale•7h ago•83 comments

Qwen3-Omni-Flash-2025-12-01:a next-generation native multimodal large model

https://qwen.ai/blog?id=qwen3-omni-flash-20251201
276•pretext•20h ago•95 comments

Fossils reveal anacondas have been giants for over 12 million years

https://www.cam.ac.uk/stories/twelve-million-years-of-giant-anacondas
52•ashishgupta2209•1w ago•24 comments

Show HN: Automated license plate reader coverage in the USA

https://alpranalysis.com
185•sodality2•18h ago•113 comments

Flow Where You Want – Guidance for Flow Models

https://drscotthawley.github.io/blog/posts/FlowWhereYouWant.html
21•rundigen12•5d ago•1 comments

Meta shuts down global accounts linked to abortion advice and queer content

https://www.theguardian.com/global-development/2025/dec/11/meta-shuts-down-global-accounts-linked...
7•ta988•48m ago•0 comments

Show HN: Wirebrowser – A JavaScript debugger with breakpoint-driven heap search

https://github.com/fcavallarin/wirebrowser
33•fcavallarin•21h ago•9 comments

Scientists create ultra fast memory using light

https://www.isi.edu/news/81186/scientists-create-ultra-fast-memory-using-light/
105•giuliomagnifico•6d ago•24 comments

Common Lisp, ASDF, and Quicklisp: packaging explained

https://cdegroot.com/programming/commonlisp/2025/11/26/cl-ql-asdf.html
87•todsacerdoti•1d ago•22 comments

Valve: HDMI Forum Continues to Block HDMI 2.1 for Linux

https://www.heise.de/en/news/Valve-HDMI-Forum-Continues-to-Block-HDMI-2-1-for-Linux-11107440.html
759•OsrsNeedsf2P•18h ago•425 comments

3D-printed carotid artery-on-chips for personalized thrombosis investigation

https://advanced.onlinelibrary.wiley.com/doi/10.1002/adma.202508890
21•PaulHoule•1w ago•2 comments

Terrain Diffusion: A Diffusion-Based Successor to Perlin Noise

https://arxiv.org/abs/2512.08309
132•kelseyfrog•17h ago•39 comments
Open in hackernews

A "Frozen" Dictionary for Python

https://lwn.net/SubscriberLink/1047238/25c270b077849dc0/
36•jwilk•2h ago

Comments

codethief•57m ago
Next step: Auto-inferring the correct (most narrow) TypedDict type from a frozendict. (Think `const foo = { … } as const` in TypeScript.) I miss this TS feature in Python on the daily.
tweakimp•46m ago
Can you give a Python example of a use case for this?
virtue3•42m ago
I also SUPER LOVE this feature. Especially when you make a type union of the keys for easier indexing.
adzm•18m ago
Curious what this means for typescript as well; honestly I've only reached for as const rarely.
mrweasel•11m ago
What would that do exactly? Auto-generate a TypedDict class?

Bringing up TypedDict is sort of interesting, because it seems like a frozen dictionary could have been implemented by PEP 705, if typing.ReadOnly was enforced at runtime, and not just a hint to a static type checker.

code_biologist•54m ago
Shoutout to pyrsistent, a personal favorite library for whenever I need to use lists, sets, or dicts as dict keys, or make sets of such items: https://github.com/tobgu/pyrsistent
polyrand•41m ago
A frozen dictionary would be very welcome. You can already do something similar using MappingProxyType [0]

  from types import MappingProxyType
  
  d = {}
  
  d["a"] = 1
  d["b"] = 2
  
  print(d)
  
  frozen = MappingProxyType(d)
  
  print(frozen["a"])
  
  # Error:
  frozen["b"] = "new"

[0]: https://docs.python.org/3/library/types.html#types.MappingPr...
drhagen•32m ago
If this gets wide enough use, they could add an optimization for code like this:

    n = 1000
    a = {}
    for i in range(n):
        a[i] = str(i)
    a = frozendict(a)  # O(n) operation can be turned to O(1)
It is relatively easy for the JIT to detect the `frozendict` constructor, the `dict` input, and the single reference immediately overwritten. Not sure if this would ever be worth it.
drhagen•29m ago
Great! Now make `set` have a stable order and we're done here.
cr125rider•8m ago
Aren’t sets unsorted by definition? Or do repeated accesses without modification yield different results?