annathepiper: (Final Test)

I spent a good chunk of today trying to figure out if I could automate some of the work of rebuilding my galleries. Answer: yes, though it took some research to learn how to do!

Because here’s the thing y’all: I had several elements in place that would allow for at least some of the restoration work to be done in a scripted fashion rather than manually.

Namely:

  1. A known directory structure
  2. One or more screenshot files in each directory in the structure
  3. A known file called metadata.json in each directory, which contained the metadata for all of the screenshots in the same directory, and which contained a known structure that I should be able to parse

And here’s the process I’ve been following to rebuild the galleries:

  1. Work my way forward in chronological order through the broken galleries
  2. For each one, find the corresponding directory on the server
  3. Manually import each screenshot in that directory into the WordPress media library
  4. Review contents of metadata.json, and copy and paste all of the relevant data out of that file onto the files added to the media library
  5. Using the FileBird plugin, create a new folder in the media library to contain the added files
  6. Using the FooGallery plugin, create a new gallery using the files in the new FileBird folder
  7. Add the newly created gallery to the relevant album of galleries, and remove the broken one
  8. Update the gallery shortcode in the relevant playthrough post from the broken gallery to the new replacement

So, a lot of steps here, right?

The problem I wanted to solve was automating steps 3 and 4, because the most time-consuming part of this process has been adding hundreds and hundreds of files into my media library, and copy and pasting the metadata in for them. (And as a reminder: these files weren’t in the media library already, because the broken galleries had been previously reading all the relevant files and data right off the server file structure. Since I can’t do that now, I have to pull all of this stuff directly into the WordPress media library.)

And solving this problem required doing these major things:

  1. Installing wp-cli, the command line tool for managing WordPress installations
  2. Learning how to use the wp media import command, including how to make it work with a multi-site installation, which is what I have; Anna Plays Skyrim is part of a multi-site WordPress network
  3. Learning how to use jq, which is a command line JSON parser

I threw some threads out on Mastodon today on the WordPress hashtag, asking for recommendations on how to accomplish what I wanted to do. So now I have a two-command solution to do steps 3 and 4 above, like so.

For step 3, I’m running this scary-looking thing which basically chugs through metadata.json in the current working directory, and spits out a full “wp media import” command for every file covered in the JSON file. Then it saves that list into temp.sh.

jq -r '.items[] | @sh "wp media import \(.file) --caption=\(.caption) --title=\(.caption) --desc=\(.description) --alt=\(.alt) --url=https://skyrim.annathepiper.org/"' metadata.json > temp.sh

Then I need to run those commands:

sh temp.sh

Lastly, I pop into the media library and confirm that:

  1. All the files in the working directory now appear in the media library
  2. All the metadata on the files is correct (and I’m correcting typos where I spot them)

Then I can proceed to making the FileBird directories and the new galleries.

So this is still taking some effort; it’s not just a matter of doing a mass import of the entire directory structure. Which I’m actually okay with, on the grounds that having to go through each directory is letting me doublecheck that the files and their metadata are getting imported okay. And look for any typos I want to fix as well.

As of this writing, I’m now at about 70 percent complete on the restoration effort. The Faanshi Playthrough and Shenner Playthrough galleries are now done.

Galleries now in active progress of being fixed are the ones for Gyllerah, Tembriel, Harrowhark, and Kendis.

More on this tomorrow. And thanks to everybody on Mastodon who offered advice!

Read more on Anna Plays Skyrim.

annathepiper: (Final Test)

I reached the point of overlapping playthroughs, so I haven’t finished up another complete set of playthrough galleries yet. So today’s work has gone into:

  • Skyrim: Faanshi, Shenner, and the Skyrim Together playthrough
  • Morrowind: Tembriel
  • ESO: Gyllerah

I am close to being done with Faanshi and Shenner but still have a few left of each of those playthroughs to finish off before I swing over into Harrowhark.

Still pending to begin: Ganniwer in Oblivion, and the current playthroughs in Skyrim, Finds-The-Way, Elessir, and Kendeshel.

I currently have a total of 576 galleries, of which 355 are now functional again. Which works out to about 62 percent complete.

Next update tomorrow night. If I continue at this rate I should finish up the gallery repair work some time this weekend, and can then start getting caught up on posting backlogged playthrough posts. I have a bunch waiting for you, y’all!

Read more on Anna Plays Skyrim.

annathepiper: My character Ysani the Breton in Skyrim (Ysani in Skyrim)

Gallery reconstruction work continues on Anna Plays Skryim, and now all galleries for Ysani’s playthrough have been restored.

I currently have 576 total galleries (because BOY HOWDY do I have a lot of screenshots for Skyrim, as well as Morrowind, Oblivion, and ESO). Of these, 227 are now confirmed functional. (Alarrah’s galleries never broke as I had never converted hers over to the gallery type I lost access to, but I’m counting hers in this count.)

Which means my galleries currently stand at about 40 percent restored.

For the time being I’m putting a pause on playing anything else, while I focus on restoring all these galleries and then working on writing backlogged posts. So it’ll be probably at least another week or so before I put up new content. Stand by, y’all!

The next round of updates will start working on three playthroughs at once, Faanshi’s, Shenner’s, and Tembriel’s. Because I’m working my way forward in chronological order through all the galleries as previously created, just because that seems the most orderly way to me to proceed.

And oh yes, one more aspect of interest to this:

When I started converting the impacted galleries back to the gallery type that pulls directly out of the WordPress media library, I had a non-zero level of worry that I’d repro the same problem that broke the galleries back in the middle of Delga’s playthrough. That issue was basically causing older galleries to lose track of their assigned screenshots.

I was worried, once I made it into Delga’s screenshots, that I’d repro that same issue. But as of this post I’ve just finished Ysani’s restoration, and I’m now well past the point (in terms of number of active galleries) at which the previous issue showed up.

So so far it looks like I’ll no longer reproduce the issue, which is good. Though I’m still a little nervous about this because I don’t know what caused the issue in the first place. And as a person whose career is software testing, a problem I don’t have a root cause for always makes me nervous.

Any number of things could have fixed it, though. Because all of these apply since the original problem occurred:

  • We had a change in internet provider
  • Operating system updates on the server
  • Multiple updates to WordPress
  • Multiple updates to the FooGallery code
  • I just installed a plugin called FileBird to help me manage the media library for this site, because I have a few thousand screenshots at this point and this makes for a very large and unwieldy library to manage without some help

Any one of these, or any combination of these, could have stabilized things enough that I no longer reproduce the earlier issue. What’ll also be interesting is whether a different issue I’ve been seeing on the site lately starts reproducing again–where galleries on older posts would render badly and I’d have to clear the site’s cached CSS data to make them work again.

Let’s hope things stay stable, anyway! Onward!

Read more on Anna Plays Skyrim.

annathepiper: My character Delga the Orc in Skyrim (Delga in Skyrim)

Work continues on restoring the missing galleries. As of this writing, I have now finished restoring all the ones for Delga’s playthrough.

While doing so, I added a bunch of play date and session number markers to her posts, similar to the practice I picked up in later playthroughs. This is to add better consistency of post format across all my playthroughs.

I also corrected a couple of discrepancies in session numbers, which means that Delga’s playthrough finished off at a total of 84 sessions.

Onward to working on Ysani!

Read more on Anna Plays Skyrim.

annathepiper: Second icon of my Skyrim character Merawen (Merawen in Skyrim 2)

The work to restore the missing screenshots of the Anna Plays Skyrim site is still in progress. But now at least I’ve finished fully restoring the galleries for Merawen’s playthrough.

While doing so, I took the time to fix a numbering discrepancy in her various galleries, and also added session numbers to all of her posts. This was a thing I started doing only after I played her. So retroactively adding session numbers to her various posts helps make them more in line format-wise with the later ones.

I found at least two instances of incorrect captions on her screenshots as well, mis-identifying things in the picture. So I fixed those too.

Onward. Next up: fixing all of Delga’s screenshots. I’ll post another checkpoint when that’s done.

Read more on Anna Plays Skyrim.

annathepiper: (Final Test)

The in-depth exploration of mods in Skyrim has begun!

I’ve been using my PC as a sandbox first, trying out mods in sequence to see whether or not I like them well enough to deploy them onto the Deck for use in official play. So right now I’m doing that with a separate character from the ones I’m actually seriously playing–which may or may not turn into an actual legit playthrough later, we’ll see. For now she’s just a test character to give me opportunity to play with mods.

Read the rest of this entry »

Read more on Anna Plays Skyrim.

annathepiper: (Final Test)

We interrupt my regular playthrough posts with this important news bulletin:

I FINALLY GOT MY STEAM DECK YOU GUYS! 😍 🤩

I’tm about to do TWO posts about this. One with general overall impressions of the thing, and also this post, which is going to be about the hoops I had to jump through in order to get at the screenshots I love to take for my playthrough posts. This did, I feel, deserve a whole separate post because it’s one of the few things I don’t like about the Deck so far. And I wanted to write up the steps I followed for my workaround, in case any other gamers out there also finally getting Decks want to do the same thing.

This is going to be long, so here’s a More tag, y’all:

Read the rest of this entry » )

Mirrored from Anna Plays Skyrim.

Profile

annathepiper: (Default)
Anna the Piper

November 2025

S M T W T F S
      1
2345678
9101112131415
16171819202122
23242526272829
30      

Syndicate

RSS Atom

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated May. 1st, 2026 02:50 pm
Powered by Dreamwidth Studios