What are you coding?

For me, it was slime and the related tooling. Don’t work with lisp much these days, so I don’t use emacs.

It’s turned out to be jolly useful on my journey into polyglot programming – there’s a syntax-highlighting mode for everything.

My staff directory API integration for Emacs (which gained numerous enhancements since I mentioned it) also led* to me putting together a framework repository to house arbitrary work-related elisp libraries for convenience, after which I added a few other things I’d written over time, which in turn caused me to do rather a lot of work improving a bunch of very old code. If only it wasn’t so satisfying to hack on Emacs features, I’d save a lot of time.

(*) It takes incredibly little prompting by any Emacs user at work to cause me to expend effort making things better for them… Happily that sometimes means making things better for me as well.

2 Likes

It was org-mode, your honour, org-mode led me into bad company.

Also the way there’s an indentation and syntax-highlighting mode for basically every programming language.

2 Likes

It’s the drug of choice for many Emacs users, but I’ve yet to fall down the Org Mode rabbit hole. The notion of organising my life in plain text sounds brilliant, but my goodness it’s a monster of a thing. I do use it for basic note-taking, and I use the Agenda in a very basic fashion, but that’s about all I know how to do. For a long time I was a bit intimidated by the idea of learning it – I mean, even the Compact Guide (“a shorter introduction to the main features of Org Mode”) is 42 pages long!

Of course there’s no reason to learn more than the particular bits which are going to be useful to you personally, and a few years ago I made an effort to get to grips with some of those things, but I didn’t absorb very much and failed to practice what I’d learned, so I’ve forgotten most of it again now.

I did make a point of writing the readme file for the aforementioned repository of elisp libraries as an org file, as our gitlab instance can render it (not as well as it handles markdown IIRC, but it still seemed like the Right Thing to do).

1 Like

Yes, as far as Real Emacs Users are considered I’m probably a heretic - I use it as an editor, but I don’t want mail and news and so on inside my editor. (I have other windows for those.) Org-mode’s export to TeX and then PDF have made it one of my two main options for writing up things that don’t need to be compatible with someone else’s page layout stream, like my compacted-and-corrected boardgame rule documents (the other is LyX).

But a lot of the utility of org-mode for me is the ease of writing programs to mess with it - e.g. every night an automated task strips out all the DONE entries in my to-do list, a command-line program lets me add things to it easily, and so on.

2 Likes

'tis the beauty of plain text file formats.

2 Likes

it’s the beauty of readily parsable file formats. In my callow youth, I was pretty vehment that meant text files, but in my mellow dottage, I can live with documented binary formats.

1 Like

I’d be pretty happy if most data was formatted as lisp-read-able s-expressions : )

I’m the guy who made his daughter a giant stuffed lambda, and I am very okay the world is not s-expressions.

3 Likes

Love your work. Can we get a photo of that toy?

1 Like


three year old for scale.

3 Likes

I spent the last 2 days writing an integration test for someone else’s code–the someone else breezed through implementing the cool new thing™ by not writing any tests and then made a ticket about “improving resilience”.

So colleague and me wrote this test. And we had trouble making it repeatable because while most tests have a built-in rollback of DB changes, this thing opens up a separate transaction for something so it was always leaking some extra DB entries. We tried eliminating the extras through the existing DB layer from the software but due to the separate transaction when we tried to delete stuff it wasn’t visible in the other transaction.

We tried and tried and tried and ended up write raw sql (no I lie, it was jpql) to go “directly” to the database to remove the junk entries. And it didn’t work. We tried opening transaction. Committing. Flushing. Nothing worked. And this is a stupid long-running test case… it took forever. We gave up.

I was off from work after lunch. Tonight saw a notification from teams and got curious: Colleague found the issue. Turns out we forgot to actually execute the statements we made.

6 Likes

Me on Thursday:

“Why isn’t this new subcommand working?”
“Because my test window is running the latest release, not the dev branch.”

2 Likes

Too often the error is: the code you are executing is not the code you think you are executing.

6 Likes

I, as oncall, got a ticket that a bunch of continuous build tests had been failing. I looked, and they were timing out. I checked back y to I when they were working, and they were perilously close to timing out then. I guess I have to figure out what is slow. Bother.

4 Likes

So, I mentioned elsewhere that I had set up an automated scanning system but that the flatbed scanner I had purchased for the task (secondhand, from eBay) was defective. I had an old HP OfficeJet 6700 which has a scanner (and a document feeder, which I didn’t have with the other scanner!), but it doesn’t have a button on the device to trigger the scan request on the raspberry pi via scanbd.

So I hacked together an awful Flask web front end to provide the necessary buttons, each running the script with different parameters that mimic the scanbd environment.

4 Likes

That looks like a web UI I’d put together. I’m not allowed to do them, for some reason.

3 Likes

I used Flask to put together a UI for some Raspberry Pi controlled bookshelf lights a while back.

It was similar, functional but not very pretty.

2 Likes

When I rewrite the guts of an algorithm and get a two orders of magnitude speed-up… I stop, and check very carefully.

(But it turns out that abandoning the highly-tweaked permutation generator and writing a much cruder one with a lot of short-cuts to bail out of branches that will never validate is in this case the right thing to do.)

6 Likes