Flickr library updates

I don’t know when this happened, but Flickr has added a bunch of new sizes to its photo offerings.

More Flickr photo sizes

Since I have several scripts and TextExpander snippets that grab the URLs of Flickr photos, I needed to update them to account for the new sizes. I finally got around to doing that a couple of days ago; the results are in my flickr-stuff GitHub repository.

I’m probably not entirely done with the updates. All the parts work, and should work for the foreseeable future, but I noticed that some of the scripts and libraries use appscript, a library that acts as Python replacement for AppleScript. Unfortunately, appscript has been deprecated by its author because he can’t get Apple’s Cocoa APIs to do what he needs and the Carbon APIs have been deprecated since Snow Leopard. To better future-proof my Flickr code, I’ll have to remove the appscript functions and replace them with calls out to AppleScript via the osascript command. On my to-do list.

My most common interaction with this code is through the TextExpander snippets that grab the URLs for the various sizes of whatever Flickr photo is frontmost in my browser.1 Here are the new abbreviations and the sizes they give:

Photo size Abbreviation
Original ;original
Large ;1024
Medium 800 ;800
Medium 640 ;640
Medium 500 ;500
Small 320 ;320
Small 240 ;240
Thumbnail ;100
Square 150 ;150
Square 75 ;75

The photo above is the Medium 640 size, and its URL is

which I just generated by typing ;640. Much faster than going to the “All sizes” page, picking the size I want, and then right-clicking to copy the link to the photo.

  1. The snippets work only for Safari and Chrome; Firefox doesn’t have an AppleScript library that can provide me with the URL of the frontmost tab.