Log

On Saturday, March 14th, 2020, the day after we were sent home on account of the plague’s arrival in New York, I started keeping a log of all of the work things that I did. With very few exceptions, I’ve kept logging every day since then. The log is now approaching 10,000 entries, so I thought I should do some sort of summary. I wrote a quick Python script to do some keyword counting, and here are the top mentions (excluding stopwords):

  1. talk (1159)
  2. email (1056)
  3. reference (776)
  4. meeting (623)
  5. work (578)
  6. committee (493)
  7. post (367)
  8. blog (316)
  9. tweeting (309)
  10. writing (303)
  11. website (275)
  12. paper (261)
  13. chat (256)
  14. send (240)
  15. alma (222)
  16. update (214)
  17. new (197)
  18. acquisitions (190)
  19. annual (189)
  20. submit (185)

I’m surprised “tweeting” is in there, as we shut down our library Twitter/X account upon Elon’s takeover in 2022, and I haven’t had a personal Twitter account since 2017. But it’s there, so it was obviously front of mind at the time.

Posted in python | Leave a comment

Further into GitHub Actions

Since my last post, I’ve been moving more things over to GitHub Actions. It has been an interesting journey. Some things are pretty straightforward to port from PythonAnywhere Tasks. Others have puzzled me a bit more.

As an example of the latter, I wanted to set up my rss-to-mastodon bot as a GitHub Action. It’s not a complicated bit of code — it posts the latest from an RSS feed to Mastodon — but one piece was tricky: the code relies on a file that contains the title of the last blog post that it has processed. How do you persist (and possibly modify) this one little piece of data across invocations?

The main challenge here is that, with GitHub Actions, you don’t really have a persistent filesystem. You do however, have a temporary filesystem pre-populated with whatever is committed to your git repository. So with a bit of yaml and bash, you can read a text file — which you’ve stored in your GitHub repository — and pass it as an argument to a Python script:

- name: 'run the python script'
  run: |
    pip install -r requirements.txt
    python fetch.py "$(< last_post.txt)"

Which works great. You can then access this positional argument with Python’s argparse library, and you’re off and running.

But we’re not done. Once your Python code has executed, the last_post.txt file needs to be updated with the latest data. You can try writing to file, you can even commit to git, but that is not going to be sufficient, because the filesystem is going to disappear in a few seconds. So you need to run through the whole add, commit and push workflow to push the changes to the remote repository (in this case, GitHub). The remote repository will be all that remains once the job runs to completion.

- name: 'commit if changed'
  run: |
    git add last_post.txt
    if [[ $(git diff --staged --name-only) ]]; then
      git commit -m "Saved new post [skip actions]"
      git push origin main
    else
      echo "No changes detected"
    fi

This bit of yaml and bash commits and pushes (if there are any changes). That’s it! If you want to see the whole workflow in yaml, it is available here.

To be clear, this is not the only possible way to solve this problem; I did consider other options (such as caching, or file storage extensions), which have their own advantages and disadvantages. I welcome your thoughts as to what you think is best!

Posted in git, github, shell, yaml | Leave a comment

GitHub Actions

Today I moved some bots from PythonAnywhere over to GitHub Actions. This is a follow-up to my previous post about migrating the front-end of the bots over to mastodon.ocert.at. Now I’m modernizing the back-end with GitHub Actions.

There were a few reasons for this switch:

  • I get GitHub Pro services for free via the GitHub Education program, so there’s really no reason to pay $5/month for PythonAnywhere.
  • As I’ve discussed before, I think that PythonAnywhere is dying, so it’s best to get out of there before things get really ugly.
  • My work with the Alma Extensibility Task Force is moving toward GitLab CI/CD, so this was a good opportunity to learn about YAML and deploying via git. This part was super interesting and I have already learned a lot. I am hoping this experience with GitHub Actions translates well to GitLab.
  • And lastly, it’s just nice to move to some more modern tooling. Shiny new things are nice.

GitHub has been catching a lot of criticism this week over on the Fediverse for rolling out their Copilot AI tool to everyone, but I’ll pass over that without comment.

Posted in git, github, pythonanywhere | Leave a comment

Coding with those who show up

This week, I have a new paper out titled “Coding with those who show up: Two methodologies on technical committee work” in Information Technology and Libraries. It is licensed CC-BY-NC, so you can read it for free here.

The point of the article is that the literature on “laissez-faire leadership” is disproportionately (and in my opinion, sometimes incorrectly) negative about hands-off leadership styles. While that literature is largely quantitative, I read it with a humanistic approach to ask whether what they say and claim is defensible. My conclusion, reading “against the literature,” is that laissez-faire leadership is sometimes — possibly under very specific circumstances — valuable and useful. This analysis is supplemented with two case studies of a laissez-faire approach in committees in our library.

I hope you enjoy the paper and I’d be curious to hear your thoughts!

Posted in leadership, research, writing | Leave a comment

Eight months with Debian

I checked the date of my previous post, and it has been eight months that I have been running Debian on this old HP laptop. Here are a few things that have struck me about the move from Ubuntu:

  1. The desktop environment can be pretty much identical. I am still running Gnome now — as I was on Ubuntu — and while it may be a different version, I would have a hard time pointing out any differences.
  2. At the outset, I had troubles with a flickering monitor. I spent quite a bit of time installing drivers and tinkering with settings, and while I can’t confidently say that it was something I did, the flickering has stopped.
  3. Debian stable’s commitment to, uh, stability, is a double-edged sword. I had been following Ubuntu’s six-month releases, and was used to having the latest. Stable moves much more slowly. I appreciate the reliability, but sometimes you just want to install something new that isn’t supported yet, and that can be frustrating.
  4. Partly as a result of (3), I find I’m building software from source more often. I almost never did this on Ubuntu, but with Debian it seems like it’s a regular occurrence.

Anyhow, these are my thoughts. My intention is not enrage some faction of linux nerds, but just to point out what I’ve noticed. I am happy with Debian; probably happier than I was with Ubuntu.

Posted in debian, linux, ubuntu | Leave a comment

CUNY IT Conference 2024

The past two days, I have been at CUNY’s 23rd annual IT Conference. It’s a conference I enjoy, even though it’s geared toward IT professionals, which I am decidedly not. Nonetheless, the smattering of librarian presentations is usually enough to keep me occupied and contented throughout the conference.

I did catch some of the presentations by the IT folk. They were relentlessly AI focused. I would be more eye-rolling about this, but some of the presenters were reasonably pragmatic about the future of AI in higher ed. Perhaps a dose of pragmatism and realism is a useful antidote to the dour doomerism I’ve been carrying around about this topic. So right now, as I sip my Friday night tea, I’m doing my best to attempt look at AI from their point of view. We’ll see if this brings any insights.

Posted in ai, conference | Leave a comment

Further thoughts on building AR projects in libraries

Caroline Jedlicka and I recently published a paper in the Journal of Web Librarianship called “Creating a Homemade Mobile Augmented Reality Game in a Community College Library: An Open Source Approach.” This link will get you past the journal’s paywall.

For me, the standout message of the article is that you do not need a professional developer to do rather interesting technology projects in libraries, like building augmented reality games. Librarians can do these things themselves, with the right support. Anyhow, the full article is available (at the link above) if you are interested in reading about our experiences. We’d of course welcome your thoughts and feedback!

Posted in ar, research, writing | 1 Response

Thanksgiving challenge, bots edition

It is getting to be time for my annual post about the Thanksgiving Challenge. Previous editions of this post can be found here, here, and here. Basically, the challenge is to spend the entire Thanksgiving long weekend coding by yourself. I’ve already covered the questionable productivity benefits (and very real mental health downsides) of doing this. But by now it’s tradition, so we’ll just plow ahead as though there weren’t any other options.

For me, this year’s challenge is going to be about bots. The venerable Mastodon instance botsin.space is shutting down, and (some of) the fediverse is in mourning. New homes need to be found for countless bots, or they will soon disappear. I have five bots on botsin.space, and I’d like to re-home three of them. The other two are, imo, not worth saving, and I’ll let them die a quiet, noble death.

Anyhow, I’ll move the good ones to the instance that I run, mastodon.ocert.at. This will provide a reliable home for the bots, although maybe with some reduced visibility, since my instance is lightly federated. Mastodon has decent account migration functionality, so hopefully that will mean that some of the people who enjoy these bots can continue to do so. From a code perspective, I can still do the compute on PythonAnywhere, and I expect that the only part of that setup that I will have to redo is the authentication.

Anyhow, have a good Thanksgiving and happy botting!

Posted in bots, holidays, mastodon, pythonanywhere | Leave a comment

Cmus

I’ve been using cmus to listen to music lately. It is rather glorious software. To see what I mean take a look at this screenshot:

It runs in the terminal and has weird key bindings. To get it running I had to build it from source. It lets me play music off my hard drive, not the network. All of these things speak to my interests, or perhaps more accurately, my aesthetic. Anyhow, the code is on GitHub, if you like.

Posted in linux | Leave a comment

SpringyCamp

This week, Carrie Jedlicka and I presented at SpringyCamp, the annual Springshare conference. Our talk was called Creating a Fun Library Tour with Augmented Reality and LibGuides! If you have a Springshare login, you can watch the video here.

It was fun, although I was nervous because there were ~300 people there! Carrie handled it like a pro. We’re glad we had the chance to participate.

Posted in conference, libguides | Leave a comment
Skip to toolbar