frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

The P in PGP isn't for pain: encrypting emails in the browser

https://ckardaris.github.io/blog/2026/02/07/encrypted-email.html
1•ckardaris•1m ago•0 comments

Show HN: Mirror Parliament where users vote on top of politicians and draft laws

https://github.com/fokdelafons/lustra
1•fokdelafons•2m ago•1 comments

Ask HN: Opus 4.6 ignoring instructions, how to use 4.5 in Claude Code instead?

1•Chance-Device•3m ago•0 comments

We Mourn Our Craft

https://nolanlawson.com/2026/02/07/we-mourn-our-craft/
1•ColinWright•6m ago•0 comments

Jim Fan calls pixels the ultimate motor controller

https://robotsandstartups.substack.com/p/humanoids-platform-urdf-kitchen-nvidias
1•robotlaunch•9m ago•0 comments

Exploring a Modern SMTPE 2110 Broadcast Truck with My Dad

https://www.jeffgeerling.com/blog/2026/exploring-a-modern-smpte-2110-broadcast-truck-with-my-dad/
1•HotGarbage•10m ago•0 comments

AI UX Playground: Real-world examples of AI interaction design

https://www.aiuxplayground.com/
1•javiercr•10m ago•0 comments

The Field Guide to Design Futures

https://designfutures.guide/
1•andyjohnson0•11m ago•0 comments

The Other Leverage in Software and AI

https://tomtunguz.com/the-other-leverage-in-software-and-ai/
1•gmays•13m ago•0 comments

AUR malware scanner written in Rust

https://github.com/Sohimaster/traur
3•sohimaster•15m ago•1 comments

Free FFmpeg API [video]

https://www.youtube.com/watch?v=6RAuSVa4MLI
3•harshalone•15m ago•1 comments

Are AI agents ready for the workplace? A new benchmark raises doubts

https://techcrunch.com/2026/01/22/are-ai-agents-ready-for-the-workplace-a-new-benchmark-raises-do...
2•PaulHoule•20m ago•0 comments

Show HN: AI Watermark and Stego Scanner

https://ulrischa.github.io/AIWatermarkDetector/
1•ulrischa•21m ago•0 comments

Clarity vs. complexity: the invisible work of subtraction

https://www.alexscamp.com/p/clarity-vs-complexity-the-invisible
1•dovhyi•22m ago•0 comments

Solid-State Freezer Needs No Refrigerants

https://spectrum.ieee.org/subzero-elastocaloric-cooling
2•Brajeshwar•22m ago•0 comments

Ask HN: Will LLMs/AI Decrease Human Intelligence and Make Expertise a Commodity?

1•mc-0•23m ago•1 comments

From Zero to Hero: A Brief Introduction to Spring Boot

https://jcob-sikorski.github.io/me/writing/from-zero-to-hello-world-spring-boot
1•jcob_sikorski•23m ago•1 comments

NSA detected phone call between foreign intelligence and person close to Trump

https://www.theguardian.com/us-news/2026/feb/07/nsa-foreign-intelligence-trump-whistleblower
9•c420•24m ago•1 comments

How to Fake a Robotics Result

https://itcanthink.substack.com/p/how-to-fake-a-robotics-result
1•ai_critic•24m ago•0 comments

It's time for the world to boycott the US

https://www.aljazeera.com/opinions/2026/2/5/its-time-for-the-world-to-boycott-the-us
3•HotGarbage•25m ago•0 comments

Show HN: Semantic Search for terminal commands in the Browser (No Back end)

https://jslambda.github.io/tldr-vsearch/
1•jslambda•25m ago•1 comments

The AI CEO Experiment

https://yukicapital.com/blog/the-ai-ceo-experiment/
2•romainsimon•26m ago•0 comments

Speed up responses with fast mode

https://code.claude.com/docs/en/fast-mode
4•surprisetalk•30m ago•0 comments

MS-DOS game copy protection and cracks

https://www.dosdays.co.uk/topics/game_cracks.php
4•TheCraiggers•31m ago•0 comments

Updates on GNU/Hurd progress [video]

https://fosdem.org/2026/schedule/event/7FZXHF-updates_on_gnuhurd_progress_rump_drivers_64bit_smp_...
2•birdculture•32m ago•0 comments

Epstein took a photo of his 2015 dinner with Zuckerberg and Musk

https://xcancel.com/search?f=tweets&q=davenewworld_2%2Fstatus%2F2020128223850316274
14•doener•32m ago•2 comments

MyFlames: View MySQL execution plans as interactive FlameGraphs and BarCharts

https://github.com/vgrippa/myflames
1•tanelpoder•33m ago•0 comments

Show HN: LLM of Babel

https://clairefro.github.io/llm-of-babel/
1•marjipan200•34m ago•0 comments

A modern iperf3 alternative with a live TUI, multi-client server, QUIC support

https://github.com/lance0/xfr
3•tanelpoder•35m ago•0 comments

Famfamfam Silk icons – also with CSS spritesheet

https://github.com/legacy-icons/famfamfam-silk
1•thunderbong•35m ago•0 comments
Open in hackernews

Uncommon Uses of Python in Commonly Used Libraries (2022)

https://eugeneyan.com/writing/uncommon-python/
99•sebg•7mo ago

Comments

iamevn•7mo ago
Seems fairly standard stuff for libraries to consider. I was really hoping for some weird stuff like patching bytecode or implementing entire different languages as a python library.
Pinegulf•7mo ago
Sure, but "Do not deprive people the joy of discovery." -Someone, not me.
ethan_smith•7mo ago
Check out Coconut (https://github.com/evhub/coconut), which implements an entire functional programming language as a Python superset that compiles to Python bytecode.
froh•7mo ago
thanks for resharing, interesting well written read

previous: https://news.ycombinator.com/item?id=32528919

pjc50•7mo ago
I briefly thought "oh yeah, mixins, shame we can't do that in C# with single inheritance" and then realized that's what extension methods are for (and slightly more general).

I have some C# code which relies on calling an extension method on a null instance, which is mildly naughty but saves a lot of refactoring.

Xss3•7mo ago
You can call methods on null instances?
pjc50•7mo ago
You can call an extension method, because it's just fancy syntax for calling a non member method with the thing before the . as the first argument. If you then don't reference it at all, it doesn't matter that it's null.
stephenlf•7mo ago
What a fantastic read. It’s nothing groundbreaking, but it’s a perfect model of how to learn good patterns.
silvester23•7mo ago
If you want to combine a mixin with a base class you have no control over, just put the base class last in the inheritance chain. Then it does not matter if it calls its super __init__.
Y_Y•7mo ago
And if there are two such base classes?
CmdrKrool•7mo ago
In the case of multiple base classes wouldn't it be more sensible for the derived class to forego the lexical convenience of super() and simply call each base explicitly? i.e.

        BaseEstimator.__init__(self, **kwargs)
        ServingMixin.__init__(self, **kwargs)
If one wants to inherit from multiple classes then they should be responsible for specifying the details of how that happens. Why should a base class be expected to add boilerplate just in case some external consumer comes along and wants to use it in some unforeseeable context?

That super() has a "method resolution order" seems like a fudge. Now 'super' doesn't necessarily mean 'superclass' anymore at the point of use. Am I missing some other hypothetical situation in which super()'s MRO brings more value for the price of having to know about this extra, implicit behaviour?

And what's funny is that in the example given, the first base class not calling super() leads to the bad consequence that the other base class doesn't get to set some internal state (self.mode). Yet in the next section, "When to use a Mixin", it advises: "A mixin is a class that [...] does not contain state"

DHRicoF•7mo ago
I could try to answer myself, but this will be far better that I could express in english:

https://www.youtube.com/watch?v=EiOglTERPEo

zahlman•7mo ago
These are things that less experienced Python programmers might not know about, but they're not at all uncommon. If anything, calling `super()` in a base class should be the default if you're designing a framework where you expect people to use mixins (or even just explicitly intend for them to derive your classes, really).

Creating blank `__init__.py` files has basically become standard because the use cases where you'd prefer to omit them don't work well with packaging tools (since everything will be in `site-packages` anyway; most people also aren't going to install multiple things from a common namespace that you publish; adding those files helps build backends and other tools understand your project layout; etc.). On the flip side, the use cases for writing something in `__init__.py` should be evident from just considering the fact that it's possible. (It's also a useful refactoring tool; if you are planning to make a package but don't know what all its modules should be yet, you can start by turning an existing `foo.py` into `foo/__init__.py`.) Preemptively importing from `__init__.py`, though, is not always a great idea; it represents extra up-front import time that clients can't opt out of. (This has a lot to do with why Pip takes a significant amount of time even when it ultimately determines that it hasn't been asked to do anything.)

Preferring relative imports is, if anything, not common enough, but is certainly common among people who know what they're doing.

As for class/static/instance methods:

> When should we use class or static methods? Here are some basic guidelines I found.

The use cases more or less derive directly from their differences. But if you're going to cite sources for this, it's a crying shame to leave out Raymond Hettinger's "Python's Class Development Toolkit" (https://www.youtube.com/watch?v=HTLu2DFOdTg).