Sunday, April 26, 2020

fragmentary notes from a bad time getting worse (2)

Disclaimer: I don’t know what I’m talking about. These posts are snapshots of what I was thinking on a given date so I can check myself later.

As I write this, early Sunday morning:

  • WHO: 2,804,796 confirmed cases and 193,710 deaths globally
  • NY Times: 938,590 cases and 48,310 deaths in the US

In my rough personal chronology, I’m marking today, or at any rate this weekend, as the point at which it seems like any very effective degree of social distancing ended locally. A steady trickle of people in neighbors' yards, a straight up party a few blocks down the way, a trip to the beer store where it was pretty clear that no one shopping or working there had any fucks left to give about transmission-limiting measures. Big packs of old guys on Harleys and young guys on crotch rockets, rumbling and screeching, respectively, through town. It’s probably not evenly distributed, but I’m guessing it feels similar a lot of places up and down the Colorado Front Range.

So: Does the disease move like I think it does after reading far too many “an expert said this” articles, or is it somehow not as bad as all that?

I think we’re going to find out, because it seems like we’ve just about exhausted whatever social / political / administrative capacity we had to mitigate things in a lot of the US.

We’ve been stricter than average about limiting contact with people outside our household, I think. We’ve got computer jobs that can happen from home, which makes that a lot more possible. Still, the social pressure to give up on it is substantial. I can feel myself shifting into the category of humorless, uptight asshole in the context of my relationships around town. Mostly, people are going to yield to pressures like that, sooner rather than later.

I wonder what this is going to look like in a week, or a month. I have some guesses and I hope I’m wrong about all of them.

p1k3 / 2020 / 4 / 26
tags: topics/colorado, topics/covid19

Tuesday, April 21

fragmentary notes from a bad time getting worse (1)

This isn’t going to be well-written and it’s probably not worth your time. I’m just pinning some thoughts where I can see them and check myself after a while.

As I’m writing this, the WHO situation report for today lists 2,397,216 confirmed cases and 162,956 deaths worldwide. For the United States it has 751,273 cases and 35,884 deaths. The New York Times map shows 804,701 cases and 40,266 deaths for the US, though it’s not yet reflected in their CSV data.

Both numbers are lower bounds on both the number of people infected and the number of dead. I’m wildly unqualified to guess how much bigger the real numbers are.

I tried to look back in my notes and see when the virus first really entered my awareness. The best I can come up with is that I remember talking about it on the phone with my dad. I was standing in a hotel lobby at a conference in San Francisco, full of coworkers who’d traveled internationally to attend. The 27th or 28th of January, I’d guess. It was in the news by then in an escalating kind of way.

A throw away line in an entry from the airport a few days later: “People in face masks because the network made them afraid of a potential pandemic.”

I think the fear really set in towards the end of February. My mom was in town and we were in the car coming back from lunch one day. I opened a laptop to check work mail and skimmed some headlines and it hit me: This one is happening. I was nervous about her taking a plane back home. The same day she left, I drank beers with a bunch of old work friends and we very carefully didn’t talk about it.

I began stocking up on canned food and dry goods in earnest somewhere around then. Work events started getting canceled. I remember a series of social gatherings haunted by that sense that this might be the last one before things got real. A series of those conversations where people said “wait, you really think this is going to be a big deal?”

I haven’t regretted those early trips to the grocery store for a second.

I started bookmarking some of my reading under a covid19 tag on the 1st of March.

In the weeks after that, I argued with older relatives and talked to neighbors and realized that the nature (and existence) of the disease had become a partisan question and a focus for the kind of conspiratorial paranoia that usually centers around chemtrails and cell towers.

Fewer people tell me it’s just the flu now. My nearest acquaintance with a chemtrails / deep state / 5G / FEMA camps obsession decamped for New Mexico a while back. I don’t think the conceptual shear has gotten any less pronounced overall, though. The focus has just shifted a little.

It was always clear that, at best, Donald Trump is morally vacuous and profoundly stupid. For a long time I had conversations where people who shared that premise would ask how much it really mattered. Sure, Trump was personally appalling, every bit the mobbed up piece-of-shit real-estate con artist you knew you were getting. But was this administration really any worse or more extreme in terms of outcomes than x-random 2020-era Republican would have been? I haven’t heard anyone ask these things lately.

Of course, a lot of people don’t share that premise. In the early days, back when I still had the capacity to worry about things like national elections, I said: It seems like the only way Trump is likely to lose the election in November is if the pandemic and its consequences get bad enough. I expected some kind of reversal in popular understanding if a lot of people died and a lot of jobs went away, but what we seem to be getting instead is a hardening cultural divide over whether the virus is itself a serious threat and whose fault it is if so.

So: The US is decently likely to have federal leadership which combines world-historical incompetence with actual villainy for the duration of this thing. As a bonus, we’re now a population permanently unable to agree on the most basic questions of fact about an event that’s going to reshape politics, culture, and the economy for decades.

Then again, I guess you could say the same about a majority of the really big things that have happened during my lifetime.

Today I feel like the American federal project is collapsing. This is an empire not just in slow decline but in a state of active disintegration. How much of that did I think already? How deep down did I feel it? I’m not sure. Maybe it’ll look different in a season or five.

Right now you can watch the cracks open in realtime. I don’t mean that there won’t be a United States of America when we wake up one of these quarantine days. I think it’s a fair bet American militaries will still be murdering people for resource extraction long after my natural lifespan runs out. But regional pandemic compacts between state governments, defunded public health agencies, and governors making back-channel deals to smuggle medical supplies in so they can’t be seized by the feds: I don’t think this stuff is ephemeral in its effects.

Structures are failing. Money and power are going to build other structures to compensate. Channels are going to shift, boundaries and systems are going to reconfigure.

It’s useful to have read The Shock Doctrine right about now.

Plenty of recent experiences have caused me to think some pretty anarchist thoughts again. The pandemic has complicated that. Or maybe it’s only informed it. My politics don’t feel any more coherent than they did 6 months ago. Maybe it would be a bad sign if they did.

The already-patchworky set of stay-at-home orders and other restrictions are about to loosen, driven partly by death-cult consensus politics, and partly just by the impossible pressures of keeping a lid on so many people and systems. Too soon and badly managed is what I expect out of this.

“Fuck you I won’t do what you tell me” is simultaneously the best and worst of American impulses.

p1k3 / 2020 / 4 / 21
tags: topics/covid19, topics/history, topics/policy, topics/politics

Monday, April 13

I learned how to dial on a rotary phone. Listen for the dial tone. Put a finger in the hole over the number you want, turn it ‘til it stops, and let it roll back. Listen to the clicks. Repeat.

In the 90s, when half of what my dad seemed to do for a living was an elaborate resource allocation game conducted in the menu trees of corporate voicemail systems, he had this gadget that would play touch tones into the handset so you could use the old rotary phones that were still littered all over the landscape. The kind of technical ephemera that you get as one kind of network thrashes its way towards becoming another thing altogether.

If you’d told me back then that I’d mourn fundamental qualities of that phone system (with its by-the-minute long-distance charges and 14.4 modems) in a time when I have access to hundreds of computers and an always-on Internet connection, I’m not sure what I would have thought.

My parents got rid of their landline earlier this year. I don’t think they would have, necessarily, but the service had degraded beyond usability by the time they finally gave up on it. For a while there, it’d go out completely if it rained enough. There was strange crackling on the line, and finally just an error tone of some sort when you tried to dial in. This is how the old world dies: Piece by piece, quietly, at the edges, a decade or three after the fact of its obsolescence.

(I wrote a draft of this fragment a month ago, and looking through my bookmarks I guess it must have been prompted by reading “A Longing for the Lost Landline”, which is exactly the sort of NYT opinion piece you’d expect from the title.)

p1k3 / 2020 / 4 / 13
tags: topics/phone

Sunday, April 5, 2020

wrt 7.0.0

Links:

It’s been nearly a year since I released a version of wrt, the tool I use for publishing this site from a collection of flat files. I hacked on it for a while late in 2019, and got somewhere in the neighborhood of a 7.0.0 release before getting sidetracked by illness, a fried computer, and holiday travel.

I checked on the state of the code last night and realized I’d left a bunch of changes dangling and had mostly lost track of the mental state I’d built up around my plans. I even had a release blog post mostly written. I went ahead and cleaned up a few obvious loose ends and published a release, which I’ll now attempt to describe.

new features

Minor stuff: There’s some refactoring, improvement here and there of how things outside of ASCII are handled, and probably a slightly better test suite (it’s still abysmal, though).

title extraction and entry caching

I decided a while ago that wrt should know what an entry’s title is, so that it can be used to do things like populate <title> tags, display navigation links for each entry, or generate an index for a site. I was already doing some of those things, on an ad hoc basis, but I wanted a general solution. Before this version, an entry like today’s would have been made up of the following files:

  • archives/2020/4/5/index
  • archives/2020/4/5/tag-wrt.prop
  • archives/2020/4/5/tag-technical.prop
  • archives/2020/4/5/tag-perl.prop

Where index contains the body of the entry for the 5th, and tag-wrt.prop says that the entry has been tagged “wrt”. The .prop extension indicates a “property”, and right now it just represents a boolean or a flag - either an entry has a property or it doesn’t.

I considered adding values to properties, based on the contents of the file, and then using title.prop to specify an entry’s overall title. So, for example, 2020/4/5/title.prop would have contained the string “App::WRT 7.0.0 …”.

It was easy to implement this, and it worked, but I wasn’t happy with it as a user. I like to change entry titles as I’m writing, and I sometimes have more than one top-level heading, or a set of subheadings in an entry that I’d like the title logic to capture. I’ve also never bothered teaching wrt to display any kind of a page / date header separately from the text of an entry, and entry titles are typically just represented with inline header tags. It seemed weird to duplicate the title into another file.

Since keeping titles in separate files is cumbersome, the other obvious option is getting them out of the body of the entry itself. wrt now does this by rendering the HTML for every entry in the archive and parsing it with a library called Mojo::DOM, then extracting the text of tags <h1> through <h6> into a title cache which can be queried later.

Out of laziness, I started adding this feature by storing the rendered HTML for each entry in memory, and accidentally discovered that by doing so I can avoid rendering most entries at least twice - once for an individual date and once for the display of every entry in a month, with a handful additionally showing up on the index page and in feeds.

As a downside, this is really slow for an operation like rendering a single entry. But at least displaying an entry can reference data extracted from all the other entries.

I feel a bit queasy about loading thousands of blog entries into memory at once in order to display any given one of them. But in thinking about it, I’m pretty sure it would have worked fine even on the machine I used to write the first version of wrt (originally called display.pl), circa 2001. In 2019 I guess I don’t really have a problem assuming that the systems I use for this will have at least half a gig of RAM. It would probably be good if wrt adjusted its behavior for really constrained environments, but my gut says that even a low end laptop or cheap shared hosting shouldn’t be too affected by this.

a tagging system

I’ve been using, as mentioned above, property files named like tag-foo.prop to add tags to p1k3 entries and display them on a topic index. This was partially supported (if undocumented) in wrt, but mostly made up of ad hoc stuff in the Makefile that generates p1k3.

Although it’s still not really documented and probably has lingering issues, this release of wrt now fully supports a similar scheme, where the filenames become something like:

  • archives/2020/4/5/indexindex
  • archives/2020/4/5/tag-wrt.proptag.topics.wrt.prop
  • archives/2020/4/5/tag-technical.proptag.topics.technical.prop
  • archives/2020/4/5/tag-perl.proptag.topics.perl.prop

A property file starting with tag is treated as a link between the entry containing it and another entry path with dots as directory separators, so tag.topics.wrt.prop tags /2020/4/5 as related in some way to /topics/wrt. If /topics/wrt exists in the archive, it’ll be rendered like usual followed by a list of tagged entries. If it doesn’t exist, it’s treated as a “virtual” entry and the tag list still renders.

This is kind of confusing, but it allows for an arbitrary number of user-defined tagging schemes.

json feed output

wrt 7 uses JSON::Feed to output JSON Feed data in addition to Atom feeds.

I’m not really sure how many feedreaders support this format, but it was relatively painless to implement, and at least NewsBlur seems to handle it.

a repl for debugging

wrt repl in a repository root will now yield a simple commandline where you can interactively inspect the App::WRT object. Handy for development purposes, more than anything.

breaking changes

I removed entry_map from configuration and hardcoded its assumptions about how entries are laid out. This is a major change if you were using it, but I’d be even more surprised if anyone had been than I already would be if anyone were using wrt in the first place. (As always, if I’m wrong, please do let me know.)

I got rid of the embedded_perl toggle, since turning it off would have broken templates. (The underlying embedded Perl feature is still in place, though I may deprecate it in future. It really shouldn’t be used for anything besides templates.)

The old (undocumented) tagging system has been ripped out and replaced, as described above.

Since it uses Mojo::DOM to parse the HTML of rendered entries, wrt will now issue warnings for parsing errors. For the most part, I don’t think this will break anything, but it may surface stuff like character encoding issues. It led to me noticing that I had some 20-year-old entries originally written in… Well, something that definitely wasn’t UTF-8, at any rate.

future work / observations

Apart from improving and fully documenting the tagging system, I’d like to spend some time making sure wrt could actually be used by someone else without the scaffolding and assumptions built into the one site where I routinely use it. My thought right now is to build a manual published with wrt itself. We’ll see how that goes, I guess.

In some ways this release feels a little shaky. It’s got ideas in it that deviate from the stark simplicity of most of this code’s history, and it brings the total of external library dependencies to 16, at least a couple of which are non-trivial. Mojo::DOM in particular makes me a bit nervous.

On the other hand, it adds a couple of things I’ve wanted for years, and some of the underlying changes are a good foundation for solving the problems that remain. I continue to think of wrt as both a format for storing writing and a concrete implementation of a tool for publishing that format. For what they are, I’m happy with both.

(Elsewhere: I’m thinking hard about how I take notes and conduct research, how doomed the web generally feels as a platform, and what language ecosystems I want to spend my remaining time as a programmer in. All of that might influence future extensions to the wrt format, or lead to implementations in something besides Perl. Time will tell.)

p1k3 / 2020 / 4 / 5
tags: topics/perl, topics/technical, topics/wrt