Published on: 2025-08-18 12:32:29
Frankenstein’s __init__ Inspired by a recent post about the woes of __init__ methods in Python, I thought I’d share the untold story of the absolute craziest __init__ I’ve come across in a production codebase. It all started when I tried to add a failing test to a Python service. The test was indeed failing, but every now and then it would fail on something unexpected. The Evidence of the Test After some minimization, this was the test I had: def test_foobar (): f = FooBarWidget () with co
Keywords: __init__ def foowidget self should_exit
Find related items on AmazonGo K’awiil is a project by nerdhub.co that curates technology news from a variety of trusted sources. We built this site because, although news aggregation is incredibly useful, many platforms are cluttered with intrusive ads and heavy JavaScript that can make mobile browsing a hassle. By hand-selecting our favorite tech news outlets, we’ve created a cleaner, more mobile-friendly experience.
Your privacy is important to us. Go K’awiil does not use analytics tools such as Facebook Pixel or Google Analytics. The only tracking occurs through affiliate links to amazon.com, which are tagged with our Amazon affiliate code, helping us earn a small commission.
We are not currently offering ad space. However, if you’re interested in advertising with us, please get in touch at [email protected] and we’ll be happy to review your submission.