Programming Update: Jan 2023 and Feb 2023


January was a relatively light programming month for me. I was focused on finishing up end of year blog posts and other tasks. Since Lastfmeoystats is used to generate the stats I need for my end of year music post, I worked on it a little to make some fixes.  The biggest fix was to change the chart titles not to be hardcoded. I didn’t realize it until I was reviewing my blog post, but I had hard-coded the year when I first wrote the code a couple years ago. I also changed the limits on some of the data I was collecting so that I could do more expansive trending for my overall stats.


February unexpectedly picked up with programming. Even more surprisingly, I didn’t start off working on the project I thought I would – a refactor of my Extra Life Donation Tracker. Instead I ended up first working on my Civilization VI Play By Cloud webhook project. I realized I didn’t have an easy way to add in new users, so I added an “add user” endpoint. It wasn’t too hard, but did require taking a hard look at some of the assumptions I’d made in the software.

The BIGGEST surprise for me was resuming work on my Go (golang) version of my Dreamhost DNS program and actually getting to a working solution in just a couple of hours; and so was born my first ever useful Go program. Back in September of last year I had tried to write this Go port of my program. The rationale was simple and two-pronged: First, I’d learned Go while doing Advent of Code and wanted to use a real program to exercise what I’d learned. Second, every time I upgrade the version of Python on my computer, the virtual environment would become invalidated and I wouldn’t realize my cronjob-based scripts weren’t working. So I wanted to take advantage of the fact that Go is a compiled language and wouldn’t need any virtual environments to run. I had been having issues understanding Go’s use of Structs to “unmarshall” (as they call it) JSON. (Definitely a place where Python is so DEAD SIMPLE!) For some reason it just clicked for me one weekend in February and I was able to create a working version. After posting to the /r/golang subreddit, I got some tips on how to make it more idiomatic Go and I spent the next couple weeks improving the code to take those tips into account.

Finally, in Feb I worked on my Snap-in-Time project. I started doing more frequent pushes to the remote backup and so those folders started getting too full of backups so I implemented the weekly culling on the remote server as well.