atlas news
    
Ned Batchelder
20  mars     15h46
Is this for autistic people?
Ned Batchelder    Special Olympics swimming season started this past weekend. A new athlete joined us, a young boy I’ll call Bryan. He asked me a question that has stuck with me.Bryan is or so, with the slightly goofy look of a boy growing into his body. He has braces on his too large teeth. It was his first...
11  mars     11h27
Does Python have pointers?
Ned Batchelder    People sometimes ask, Does Python have pointers I hate to be the typical senior engineer, but this is one of those questions where the answer is, it depends what you mean by pointer.The classic definition of a pointer is: a variable that holds the address of something else and that you can use...
12  février     19h21
Updated multi-parameter interactive Jupyter notebook
Ned Batchelder    A few years ago I wrote Multi parameter Jupyter notebook interaction about a Jupyter notebook. It worked at the time, but when I dusted it off recently, it didn’t. I’ve renovated it and cleaned it up a little, and now it works again.It’s a Jupyter notebook with a simulation of late career money...
10  février     11h50
One way to package Python code right now
Ned Batchelder    A year or so ago, I couldn’t find a step by step guide to packaging a Python project that didn’t get bogged down in confusing options and choices, so I wrote my own: pkgsample. After I wrote it, I found the PyPA Packaging Python Projects tutorial, which is very good, so I never made a post here...
30  janvier     14h08
I am at liberty
Ned Batchelder    As of a few weeks ago, I am between gigs. Riffing on some corporate speak from a recent press release: U and I have mutually determined that U is laying me off. I feel OK about it: work was becoming increasingly frustrating, and I have some severance pay. U is in a tough spot as a company so...
24  janvier     11h38
You (probably) don’t need to learn C
Ned Batchelder    On Mastodon I wrote that I was tired of people saying, you should learn C so you can understand how a computer really works. I got a lot of replies which did not change my mind, but helped me understand more how abstractions are inescapable in computers.People made a number of claims. C was...
14  janvier     14h39
Randomly sub-setting test suites
Ned Batchelder    I needed to run random subsets of my test suite to narrow down the cause of some mysterious behavior. I didn’t find an existing tool that worked the way I wanted to, so I cobbled something together.I wanted to run random tests out of , and keep choosing randomly until I saw the bad...
27  décembre     23h03
Coverage.py with sys.monitoring
Ned Batchelder    New in Python . is sys.monitoring, a lighter weight way to monitor the execution of Python programs. Coverage.py . . now can optionally use sys.monitoring instead of sys.settrace, the facility that has underpinned coverage.py for nearly two decades. This is a big change, both in Python and in...
10  décembre     18h21
Real-world match case
Ned Batchelder    Python . brought us structural pattern matching, better known as match case. At first glance, it looks like a switch statement from C or JavaScript, but it’s very different.You can use match case to match specific literals, similar to how switch statements work, but their point is to match...
29  novembre     23h30
Say it again: values not expressions
Ned Batchelder    Sometimes you can explain a simple thing for the thousandth time, and come away with a deeper understanding yourself. It happened to me the other day with Python mutable argument default values. This is a classic Python gotcha : you can provide a default value for a function argument, but it will...