HNHacker News
TopNewBestAskShowJobs

emidln

3,031 karma · joined November 7, 2011

I mostly use eBPF/C/C++ these days but I used to write lots of Clojure, Python, Java, and SQL, with smatterings of Lisp, Ruby, and Javascript where need be.

I'm attached to a tmux session. gdb is probably running in a split with vim.

My views are not necessarily those of my employer.

I live in the Chicago burbs, but I work in the loop. I'd love to buy you a tea, coffee, or a beer to talk about start ups, Clojure, C++, Lisp, Python, toolchains, Bazel or other tech.

github: https://github.com/emidln

bsky: https://bsky.app/profile/emidln.com

email: emidln@gmail.com

submissionscomments
emidln··on Why Polars rewrote its Arrow string data type
Wouldnt you just recompile your duckdb with the hacked Arrow?
emidln··on No price Microsoft could pay Apple to use Bing: Google antitrust ruling excerpts
One way you might fund a search engine is if you needed the index for some other busineds purpose (say, Siri). It will have a cost, but if you can defray the crawling and some processing cost, it becomes much easier to stomach without ads.
emidln··on Why Italy Fell Out of Love with Cilantro
As an aside, why add footnotes with misc words/brands rather than numbers?
emidln··on Ask HN: What macOS apps/programs do you use daily and recommend?
It only allows simple rebinds, although maybe this makes Karaviner-Elements not necessary for most people.

MacOS can do caps lock to control or caps lock to escape. I bind caps lock to escape if pressed alone or control if pressed together with another key.

emidln··on Ask HN: What macOS apps/programs do you use daily and recommend?
Besides the usual Firefox/Chrome, Spotify, etc I use the following:

- Karabiner-Elements[0] for key remapping, specifically, for making caps lock into ctrl/esc. I don't know of anything else that does this job. Everyone who remaps keys seems to use this.

- Kitty[1] as my terminal of choice. I spend most of my time logged in remotely to a server via ssh where I attach to a tmux session. Kitty was easy enough to configure/theme and seems well-documented.

- Hammerspoon[2] for a DIY automation/keybinding/window management sys scriptable via lua. I use a private fork of this config: https://github.com/jasonrudolph/keyboard/tree/main

- Vivid[3] to make my macbook's screen brighter when outdoors on sunny days. This is important for me, since I try to spend as much time outside as possible.

[0] https://karabiner-elements.pqrs.org/

[1] https://sw.kovidgoyal.net/kitty/

[2] https://www.hammerspoon.org/

[3] https://www.getvivid.app/

emidln··on My favorite programming problem to teach: Digit length (2019)
len() is an O(1) lookup of the stored length on the unicode/bytes object in Python.
emidln··on Don't DRY Your Code Prematurely
Bazel solves this exact problem (coming from its macrosystem) by allowing you to ask for what I term the "macroexpanded" BUILD definition using `bazel query --output=build //some/pkg/or:target`. When bazel does this, it also comments the file, macro,and line number the expanded content came from for each block.

This gives us reuse without obscuring the real definition.

I automated this in my emacs to be able to "macroexpand" the current buid file in a new buffer. It saves me a lot of time.

emidln··on GCC 14.1
It's great seeing progress made here. C/C++ will never be truly safe languages, but every little bit the compiler can help with is appreciated, esp by those maintaining established codebases.
emidln··on FTC announces rule banning noncompetes
In finance, it's common to see a base of 150,000 and a VR of between 300k and 750k for engineers. During garden leave, you get paid your $150,000 as part of payroll, but are ineligble for VR. Your total comp goes from 450,000 (in mediocre years) or 900,000 (in good years) to 150,000 for whatever your non-compete period is (6 months, 12 months, 24 months are all common).
emidln··on PfSense Software Embraces Change: A Strategic Migration to the Linux Kernel
There was also a Gentoo effort to run atop FreeBSD[0]. The challenge of course is that afaik none of the BSD kernel ABIs are considered stable. The stable interface is the BSD libc. That said, with binfmt_misc, I don't see a reason you couldn't just run (at least some) FreeBSD binaries on Linux with a thin syscall translation layer (rather something like qemu-system) and then your layer hooked via binfmt_misc. I'm not aware of anyone who has done this for FreeBSD, but prior efforts existed as alternate binfmts for SysVr4/5 ELF binaries[2]. Either way would take some elbow grease, but you *might* even be able just reuse binfmt_elf and just have a new interpreter for FreeBSD elf.

[0] https://wiki.gentoo.org/wiki/Gentoo_FreeBSD

[1] https://docs.kernel.org/admin-guide/binfmt-misc.html

[2] https://github.com/torvalds/linux/blob/master/fs/binfmt_elf....

emidln··on RustPython
I've used pypy in anger a few times. I haven't needed to do reasonably performant webdev in python for awhile, but there was a time when PyPy and the cffi-based database drivers could not be beat by CPython interpreters for non-trivial code. This still might be the case, but I haven't profiled it at all (recently). This was back in python 2.7 days in the mid 2010s.
emidln··on A Tour of the Lisps
Why can't you just put the equivalent of `(repl)` wherever you want to debug and drop into your REPL?
emidln··on NY Governor vetoes ban on noncompete clauses, waters down LLC transparency bill
This is the risk they take in exchange for being able to fire me at will.
emidln··on A coder considers the waning days of the craft
If the someone elses on my team can't read a short shell pipeline then I failed during interviewing.
emidln··on U.S. Teens Spend Average of 4.8 Hours on Social Media per Day
Indeed, when I was a teenager I spent at least 5 hours a day chatting on Yahoo Chat/IRC, getting into flamewars on mailing lists, etc.

Was that any different? I'd find it hard to believe GNU/Linux vs Linux or Slackware vd Red Hat Linux was worth any more than random dancing or makeup tutorials.

emidln··on Bad Emacs defaults
I know of at least two `mg` users (a barebones C impl of emacs) that use it for almost everything (including c++ and python). That's `emacs -Q` to the extreme.
emidln··on A California hedge fund bulldozed state labor laws, imposed harshest noncompetes
We're told from the start to live within our salary and investment returns. If you make $200k base, usually make about $1m TC and choose to spent all of your cash every year, I don't feel esp bad for you. The operative word from VR is variable. Leaving, not negotiating a sign-on bonus with the new firm, and getting your garden leave enforced isnt much different than a bad year wiping out your VR, except you have to make your own mistakes at every turn to put yourself in that situation.
emidln··on A California hedge fund bulldozed state labor laws, imposed harshest noncompetes
I've black lined a lot of clauses in employee agreements like the one in the article. When questioned by the company I tell them I cannot agree to such terms at the salary being offered and generally propose what I consider to be an outlandish number as salary plus paid PTO in exchange for it. Typically, the company just signs. Sometimes they tell me to eff off. Only once has someone paid me what I thought was an absurd rate to not work for their competitor.

My current non-compete is in the finance industry and uses paid salary during garden leave as a way of avoiding non-compete laws. Nobody esp cares whether it is legal since its a year or two paid vacation.

emidln··on -Werror Is not your friend (2017)
You bump the version gcc.spec in say, Fedora rawhide. What happens when random package foo doesnt compile with it? Foo is fixed or you skip that gcc version. Unless foo is very important and very hard to fix, you fix foo.

Distros already enforce a consistent toolchain. Arch, Debian, Fedora, Gentoo, etc.

emidln··on -Werror Is not your friend (2017)
Reifying the toolchain dependency is the point. If you don't do this, you're fucked anyway.
emidln··on ChatGPT-4 significantly increased performance of business consultants
> Actually a robot would be perfect at that. No one likes doing layoffs but chat gpt won't mind

Maybe chatgpt should be trained to care.

emidln··on How does Linux start a process
The source code to the kernel's elf "binfmt"[0] is very readable. The elf binfmt is registered (along with a few others like `binfmt_misc`) and you get dispatched there via `exec_binprm`[1] which is invoked by the `execve` syscall[2]. When loading a shared library, you also dispatch to a binfmt via the `uselib`[3] syscall.

[0] https://github.com/torvalds/linux/blob/9fdfb15a3dbf818e06be5...

[1] https://github.com/torvalds/linux/blob/9fdfb15a3dbf818e06be5...

[2] https://github.com/torvalds/linux/blob/9fdfb15a3dbf818e06be5...

[3] https://github.com/torvalds/linux/blob/9fdfb15a3dbf818e06be5...

emidln··on Delphi 11 Community Edition
I treat picking uncommon OSS packages as adopting a bit of software. As I verify the tests look good, the build system, the api, the correctness, etc I also consider the code style and whether I (or my team) could maintain/patch it if needed. Adopting a bit of OSS is saving me some initial work, but doesnt absolve me of my responaibility to maintain it in the future. My business doesn't care whether the bug is one I wrote or one I greenlit externally, they just want the business app to work well.
emidln··on What Is Dimensional Analysis?
I had a high school physics teacher who would have the instructions "Answer in SI units unless specified" at the top of his exams, but there was always a last bonus problem that referenced the previous answer and promised extra credit equal to a full problem for the answer in "most creative or interesting units (with work shown)". It was a competition in the class for the extra credit and he'd typically award 1-3 of the answers full extra credit.
emidln··on Show HN: I built a Python web framework
Most nontrivial Django websites also have varying structures. At least they did a decade ago when I was working as a consultant specializing in Django. About as much commonality as Flask. Did Django ever figure out a less verbose way of declaring REST APIs with arbitrary serialization?
emidln··on I worked in federal prison sweatshops for 23 cents an hour
It's a travesty that slavery is still legal in the USA. These slaves also compete against free citizens who would otherwise be employed for these positions. UNICOR isn't just stealing from inmate slaves, it is stealing from average americans who would otherwise be employed by factories making stuff that, by law, must be purchased from a company that makes in America.
emidln··on Block YouTube ads on AppleTV by decrypting and stripping ads from Profobuf
There's no reason to allow arbitrary traffic in either direction other than convenience. If you want a more secure network, you block everything by default and narrowly open as needed.
emidln··on Math for kids outside of the Calculus Sequence
>> you as an adult get asked to “stop helping them get ahead of the class” > Whether by parental training or self study, some teachers treat it almost as a crime to understand the material before the class starts.

I remember a 7th grade math teacher confiscating my workbook when she found out I had done the entire workbook in the first week. I never really understood why. I spent most of that year telling the teacher she already had my homework and refused to do it again on principle. I ended up taking a 0 on every homework assignment and had a C in the class instead of an A+. Fuck that teacher.

> In college you can sometimes talk your way out of the Intro To XYZ classes and go directly to the upper level stuff.

I did this for first year history, computer science, and calc classes. Highly recommend giving it a try.

emidln··on IBM, Red Hat and Free Software: An old maddog’s view
> each release of CentOS Stream is a frozen Fedora release

This is the current state. Why should IBM maintain rolling updates into Fedora ("rawhide"), then cut a Fedora release, then bless a Fedora release as Centos Stream, then backport from rawhide to Centos Stream as needed until they decide to cut a RHEL branch? If I were an exec at IBM, that would seem like a lot of extra releng salary that could be better spent directly on core product (which is RHEL which comes from Centos Stream) or billable hours. Someone's bonus can go up a few bills by eliminating a line item while improving efficiency.

Why should IBM continue paying for rawhide -> fedora release -> centos stream -> rhel ? How long until the fedora release step is put out to pasture then eventually culled?

emidln··on IBM, Red Hat and Free Software: An old maddog’s view
I've used Red Hat Linux (first Caldera Linux, a 90s era clone), then Fedora, as well as RHEL and its clones (Scientific, Centos, Rocky) since the late 90s. I've used it personally, pedagogically, and professionally. I recommendeded it to others for their desktops and servers. If you wanted to use Linux, I'd tell you there are two options that are stable and well-supported: Red Hat and Debian. Red Hat has died recently. RIP.

I'm no longer confident that Fedora will continue to be a thriving open-source project. If IBM is killing RHEL clones now, why risk Fedora being next?

I hear you saying "RHEL is derived from Fedora" and "Fedora is a separate open-source project". The thing is, RHEL is derived from Centos Stream *now*. Why does Fedora need to exist? Or rather, why does Red Hat need to provide engineering and infra to Fedora? It's true that Fedora is a separate project, but its mostly contributed by Red Hat employees. If IBM decides tomorrow to stop paying for Fedora because Centos Stream is enough, can Fedora stand alone?

Maybe this is just FUD, but I no longer have confidence in an IBM owned Linux distro. I've already moved to Debian for personal machines, and I've been advocating it professionally as well. It's just irresponsible for an org that spends significant engineering time customizing their Linux installations to base on an uncertain Red Hat/IBM backed distro over a fully open-source project with no strings attached. Fool me once shame on you but fool me twice and, well, IBM isn't going to get me again.

← PreviousPage 2 of 30Next →