The Year in Review

Org Mode

Org Mode is a note making and task management system on the venerable Emacs text editor. I transferred my org-mode set-up to my latest laptop some time ago - I had been running it on a live distribution I have been using for writing for a little over a year - and, almost inevitably, something broke. Specifically, Org Journal was thrown out and I could no longer use the function org-journal-new-date-entry which should run upon my pressing F9, asking for a date in the future to add an entry. This slows me down since it is through this function that I can add an entry with nothing more than a couple of key presses1 in order to add, say, a date for a a booster vaccination upon reading an email, a class I will be substituting after reading an SMS, or a meet-up with a friend following a phone call; the precise point of such bindings is that muscle memory is fast and efficient, and so it’s a pain to throw something out however easily it would be to think of a different approach.

Anyway, so what did I have to do? Well, the error that was being thrown was the following:

Created property regex (\(?3:[0-9]\{2\}\)\(?2:[0-9]\{2\}\)\(?1:[0-9]\{4\}\)) doesn’t match CREATED property value (nil)

Now I originally broke org-journal soon after I learned to use it so effectively that it became essential. I was sheltering in place on a vineyard in Moravia owned by my ex’s father. I had been working remotely throughout the pandemic and had been going stir crazy stuck in Prague and so, by the time it came to harvest, the idea of the kind of combination of headwork and manual labour the vineyard demanded seemed like a good combination. So too would it get me out of a social circle that had been getting into every species of viral New Age nonsense that come to feel like some white post-communist version of The Buddha of Suburbia. I tend to handle periods of changes to my routines by drilling down into finnicky technical tasks and so, settling into the routines of the wineyard, where I was living on my own, I took to playing around with my set up which involves Emacs itself, the org-mode text files, and a number of Python scripts. Org Journal entries can be daily (the default), weekly, or monthly. I was keen to use monthly and had attempted to change my configuration but had written a string "monthly" in place of a variable 'monthly. Now this was not ideal at a time that I had to keep on top of my own work and all of the unfamiliar tasks at the vineyard. In my experience, most coding issues are resolved by some trivial tweak such as this change of three characters. Unfortunately, most coding issues are also solved by iterating through a list of potential issues as it is being appended to as one expands one’s knowledge by finding many of the ways not to solve it. As a consequence, it is typically impossible to know whether a given problem will be resolved in 1 or 100 hours. Which is problematic in terms of setting priorities since it is impossible to know whether the investment of 1, 2, 4, 8 hours will make one more productive or be a complete waste of time.

So what does the error message above tell us. A year ago, I could certainly guess, but lacked precision. A regex, or “regular expression”, is a series of characters which match an alpha-numerical pattern such as an email address (typically an arbitrary series of numbers and letters which may include a dot or two, followed by the @ character and a domain such as “gmail.com”) or, as in this case, a date. The above regex, which includes a number of escape characters such as “", is constructed to match the date format ddmmyyyy in a CREATED block such as the one below.

* Saturday, 15 January 2022
  :CREATED:  15012022

In order to solve the first problem I encountered with Org Journal back in the autumn of 2020, I had to read the code, which is written in a language, Elisp, which I use periodically but am not wholly familiar with. By doing this, I could trace the error through the function calls, seeing the variable mentioned above in context. I have not yet dived into the code this time around but, from the occasions I encounter the above error, it seems that Org Journal has to find the correct file, and the correct entry of that file, by iterating through all of the various entries in the journal files which, like the example above, contain a date in a given format. Since it is parsing plain text, this search for the appropriate entry is rather brittle. So far, I have found four or five types of error, two of which appear to be more likely to be significant. The first is an error introduced from a time I had a configuration which outputted a different date format, the for me utterly unintuitive yyyyddmm. The second was introduced by a laptop I sometimes ran my live distribution on whose locale was in Czech, meaning that the names of days and months were in Czech.2 The third, probably more minor error, involved entries which might have been created or edited by hand and which either lacked a :PROPERTIES: drawer or had been orphaned from it. The fourth and fifth errors also involve manual entries or poor edits in which I had inroduced a second comma following the name of the month, or written a month in lower case.

What did all this mean? Well, over the last few days I have spent an hour here and there going through old journal entries. Which sounds like precisely the kind of niggly faff that many people leap upon whenever anybody describes a GTD-style3 system of task management. “It all sounds like a lot of hassle”, they will say, sure that it takes more time to maintain such a system than is gained by using it.4

Like a lot of people I know, I was ill for a time in December and, since I have neither the internet nor a television at home, and since I did not invariably have the energy to read either The Age of Surveillance Capitalism or the excellent but equally grim Andel by Jachym Topol, I wound up going through every podcast and audiobook on my iPod Touch (I don’t have a smartphone). One of these was a Czech edition of The Bullet Journal Method. I am certain I must by now sound like precisely the kind of task management system obsessive remarks such as the one in the last paragraph are aimed at and about whom they may often be accurate. In fact, the book had been bought by my ex with whom I share an account5 and, though I thought it might throw up an insight or two, I chose it having ran out of much else and thinking, correctly, that it would for the most part be the kind of uninvolving backdrop I could put on and more or less forget about.

The Bullet Journal Method began as a blog and, like many another system which, in order to be packaged as sold as the latest book that will change your life, is padded out with marketing-honed slogans and hyperbolic claims. Also like many another such system, it makes a decent point here or there. One of these relates to the very neccesity of looking over one’s past entries if and when one must transfer them, perhaps to a fresh page. Something similar happened with the Emacs configuration SNAFU I describe above. Because were it not for being forced to go through those old entries, I would have done little to learn from the past year in the round and reflect upon it.

Little! Well, I have a habit or three. As an example, two of the capture templates I describe above are “What Worked” and “what didn’t work”. If I struggle to sleep and wake groggy and barely functional after drinking wine, I make a note: it doesn’t work for me. This is not so I live like a monk and I might periodically decide that a decent night out (when it’s possible) is worth the ensuing hangover (when you plan the next day around watching undemanding films or what have you, this is perfectly reasonable once in a while), but how many people’s lives are defined by the same handful of maladaptive strategies and bad habits? Still, I come across these entries once every month or two, perhaps more frequently, when I commit the repository and inspect the changes, and there are more regular glances over things when I do a weekly review.6 Patterns over longer periods of time seem rather onerous to look over and annual review can be skipped.

And so here now is the pay-off for those of you who have waded through the technicalities above. Because Ryder Carroll, the author of the Bullet Journal Method is certainly correct when he discusses the difficulty of reflection in the age of networked computing and, in particular, the last period of development of apps, games, and services which are designed and finessed to be maximally addictive and to produce the greatest amounts of what Shoshana Zuboff calls “behavioural surplus”. I do not wish to dwell on the number of people I know who do not appear to reflect at all, nor think about the degree to which some of them have invested in a persona and accompanying personal brand, which they insistently send out into the world and, over time, come to believe. The last year or two must surely have given us much to think about, if only we could find the time. These have been two exceptional years and it is far from clear that we will ever return to whatever was thought to be the pre-existing “normal” some people continue to talk about. For me it is of little importance whether one has a habit of keeping a diary (ie. since this seems decreasingly clear, a written record intended only for oneself), a sketchbook, bullet journal, or something like org-mode (which, importantly, is a series of files which need not leave one’s computer still less be synced to “the cloud”). All of these are systems which permit one, indeed force one, to reflect on a regular basis on one’s life. All of them will throw up their own discontinuities and will in one way or another deliver regular or irregular moments of serendipity where one is confronted with one’s past self, actions, thoughts, ideas, impressions, and decisions. In the context of the world Zuboff describes, such a system seems to be the only reliable way to deliver something by way of resilient human agency in a world which is increasingly hostile to it.

I am still processing what I have learned from this latest fish eye view of my life over the period of the pandemic. What is certain, however, is that, with regular changes of routines, with a change of living arrangements, and a number of projects and activities including but far from limited to making wine for the first time, unsupervised, on a wineyard in Moravia, the completion of two major translation projects, and the submission of a literary translation for which I was shortlisted and praised, I would not have remembered, or reflected upon a fraction of it. What is equally certain is that, without the system I managed to set up and debug around the time I was settling to work, not only on making wine, back in October of 2020, I would not have managed half of it, and would have known far more stress.

It is possible that 2022 will see something of a change to my workflow. I have been writing longhand more of late and some task lists and the like may be transferred to paper. For the moment, however, for the geeks among you, my currently clocked task, my context, and the number of complete / incomplete tasks marked as priority A, B, and C in my current session file are outputted in my Sway bar ie. the information line of my windows manager. I use a combination of Python scripts, Sway, Tmux, Magit, and Zshell to help me to keep on top of things with a minimum of friction. Since you are likely not here unless you have one of my email addresses, you may contact me for more details should you be interested in learning more.

Example of regex

As mentioned in note 3 below, the following example is a regex in Python. “re” is the module used for regular expressions, “allens” is a list of strings which we will check against our pattern, which is stored in the variable “pattern”. The “for string in…” line stores each of our name candidates in the variable “string”, passing it to the following indented lines ie. in this case just the one, which tries to find the pattern in the string. Rather clumsily outputted here (I am giving the raw output rather than, say, storing the result in a variable and perhaps giving feedback in English ie. “The string ‘David Allen’ is a match for the regular expression ‘David Al{1,2}[ae]n’.” I could also have thrown in a more obviously incorrect name such as “Dafyd Alun”.

>>> import re
>>> allens = ["David Allan", "David Alan", "David Allan", "David Allen", "David Alen"]
>>> pattern = "David Al{1,2}[ae]n"
>>> for string in allens:
...     re.match(pattern, string)
<re.Match object; span=(0, 11), match='David Allan'>
<re.Match object; span=(0, 10), match='David Alan'>
<re.Match object; span=(0, 11), match='David Allan'>
<re.Match object; span=(0, 11), match='David Allen'>
<re.Match object; span=(0, 10), match='David Alen'>


Image: 2015-02-09 Capturing Org Mode notes more efficiently CC BY Sacha Chua

  1. I have set up a key binding in the Sway window manager that opens Emacs in the foot terminal and runs my org capture template so that I can store todo items, ideas, various diary entries and the like (I have 12 capture templates and use all of them sometimes, many in flurries, and some of them regularly) easily even from the GUI.

  2. I have not yet seen a regular expression for the initial entry title but it could break in one of two ways: it might check for the full text of, for example “January”, “February” etc., but it might also simply check for an initial capital letter followed by a series of letters. Either of these implementations would fail on the named of Czech months and days which by convention are written in lower case. Some implementations might involve a further fail case in which letters are defined as A-Z or a-z exclusive of accents, impacting eg. the first letter of the Czech word for February: “únor”.

  3. I have read David Al{1,2}[ae]n's Getting Things Done but am sure that org-mode predates the book. For good or ill people tend to use “GTD” as a catch-all for task management systems and so I use the term here. I have written his name in the first sentence of this note as a regex as I am currently off-line, do not have a copy of his book, and am not certain how his name is written. The regex matches a number of different possible spellings of his name (though one is highly unlikely in English). This does not do much for readability but does give an example of the kind of situation that might lead a programmer to reach for a regex; one excellent guide to Linux and UNIX administration I have sets a deviously complicated task for the reader to construct a regular expression to check for the various transliterations (spellings) of the name Muhamar Gaddafi, none of which I have likely managed here… On line having posted, it is of course, David Allen and… well, the other name is a transliteration so it only comes down to conventions, but Wikipedia has it as Muammar Gaddafi.

  4. Undoubtedly true for some people and some implementations.

  5. I have enriched her collection to the tune of ie. Bohumil Hrabal, John le Carre, George Simenon, Jaroslav Kmenta, and Virginia Woolf, she mine to the tune of Frank Herbert, Ellena Ferrante, Agatha Christie, Andrzej Sapkowski, Michael Zantovsky and, interestingly, Stephen Hawking, since I can’t remember downloading a Czech copy of A Brief History of Time. (There are few women in my collection, it strikes me now, which is unfortunate and, I think, unrepresentative: two of my favourite writers are Alice Munro and Grace Paley.)

  6. For years I tied my weekly review to the event of my recieving a new copy of the New Yorker. This went awry some weeks back when the post was disrupted by christmas and, perhaps Covid. I have now changed back to the London Review of Books which was once a biweekly and became a monthly (though I may be mixing it up with Literarni noviny which did the opposite some years ago).