Screwtape screwtape@identi.ca

Sydney, Australia

Font nerd, photo nerd, Linux nerd, Python nerd, web nerd. I make great toasted-cheese sandwiches

  • 2017-10-07T10:35:13Z via Identi.ca Web To: Public CC:


    I don't have any production responsibilities right now, but when I did, it was always a challenge to figure out what led up to a particular failure and what might have caused it—lots of grepping of logs, and applying hard-won knowledge of all the intricate steps of whatever process had failed. Having some kind of correlator tool to automatically record that these log messages came from that process, as part of answering this query would have been great.

    The video actually goes one step further, demonstrating a system that not only finds all the details of a particular problematic query, but can find and summarize all the other queries contending for the same resources, which is amazing: usually when something fails, it's not because it actually broke, it's because some other thing changed the environment in an unforeseen way.

    Unfortunately, this is more a design pattern than an actual product (proprietary or open source), but I'm definitely going to keep it in mind the next time I have to add monitoring to something.
  • 2017-10-04T10:19:32Z via Identi.ca Web To: Public CC:

    The "Strange Loop" conference was held recently, and I'm picking my way through YouTube recordings of talks, looking for interesting stuff.

    Rebuilding The Cathedral talks about FLOSS maintainership. In 1999, Eric S. Raymond's essay The Cathedral and the Bazaar talked about the difference between traditional, centrally-planned software development and the amazing, egalitarian, decentralized future of FLOSS software that was about to descend. Nearly 20 years later, we know things didn't work out that way: only a tiny fraction of FLOSS projects have any kind of "bazaar" culture, and the vast, vast majority of them have only a single maintainer. The vast, vast majority of contributors only contribute once and then move on, rather than hanging around to share the maintainership load.

    Somewhat frustratingly, the talk doesn't really have any particular insights about what a "healthy" FLOSS project should look like, if not a Raymondian bazaar, or even what healthiness is, in this context. Nevertheless, I appreciated the wake-up call and I'll try to have a more open mind about what constitutes "success" for the projects I follow and whatever I might work on myself.

    Charles Stanhope, Claes Wallin (韋嘉誠) likes this.

    Scorpio, Scorpio, Scorpio and 5 others shared this.

    Here's nayafia's repo with an overview of ways of funding free software, and links to concrete examples of projects, plus case studies, for each form of financing.

    https://github.com/nayafia/lemonade-stand

    Claes Wallin (韋嘉誠) at 2017-10-05T04:21:41Z

  • 2017-09-19T09:55:25Z via Identi.ca Web To: Public CC:

    How to disable DRM support in your browser of choice:


    I was pleased to discover you can actually disable DRM support in Chrome, and amused to see how deeply buried it is. The phrase "bottom of a locked filing-cabinet stuck in a disused lavatory with a sign on the door saying Beware of the Leopard" springs to mind.
  • 2017-09-06T12:32:49Z via Identi.ca Web To: Public CC:

    If I require three items to do some task, but only have two, I would say I have "two out of three", or "2/3".

    For whatever reason, /proc/mdstat in Linux reports a degraded RAID-5 array (two working drives, one failed) as having "3/2" drives.

    This was super confusing to me, especially since I also had a RAID-1 partition on the same host that had two working drives out of two required and one spare, which I would legitimately describe as "3/2".

    I guess as a kernel interface to userspace, the contents of /proc/mdstat are set in stone and can never be changed... but I wish somebody had picked that up when the Linux software RAID feature was being reviewed.
  • 2017-08-20T06:52:57Z via Identi.ca Web To: Public CC:

    I wanted to answer a simple question: was Mastodon growing as fast as it was back in April, and if so, why wasn’t I seeing more friends on the service? The answer seems to be that Mastodon continues to grow, but a major engine of its growth is Japanese erotica.
    I guess this is the social medium free of central control that we asked for?

    AJ Jordan likes this.

    AJ Jordan, AJ Jordan, AJ Jordan, AJ Jordan and 2 others shared this.

  • 2017-08-02T05:05:07Z via Identi.ca Web To: Public CC:

    Is there such a thing as a grammar-checker I can feed Markdown into, and get GCC-style "filename:line:column:message" records out the other side?

    Claes Wallin (韋嘉誠) likes this.

    Claes Wallin (韋嘉誠), Claes Wallin (韋嘉誠), Claes Wallin (韋嘉誠), Claes Wallin (韋嘉誠) shared this.

    "Markdown implementations have diverged considerably over the last 10 years. As a result, users are often surprised to find that a document that renders one way on one system (say, a GitHub wiki) renders differently on another (say, converting to docbook using Pandoc)"

    Since there are so many different variations of Markdown that exist the first question should probably be: Which Markdown do you ask about? John Gruber's original (and unmaintained) version from 2004? GitHub's version of it? Or PHP's version of Markdown? Or Pandoc's version? Or maybe CommonMark? Or maybe one of the other variations?

    Jason Self at 2017-08-02T13:10:42Z

  • 2017-07-31T12:31:29Z via Identi.ca Web To: Public CC:

    A long time ago I heard that Sun was working on a JVM-based language called "Fortress" that (broadly) aimed to do to Fortran what Java did to C++... and then I never heard any more.

    Today somebody mentioned that Guy Steele gave a talk at JuliaCon 2016 called Fortress Features and Lessons Learned, and I'm finding it really interesting. Python is sometimes called "executable pseudocode" but only for programmers; apparently, Fortress was designed to be executable pseudocode for mathematicians: a mixture of programming and mathematical notations that can be used for high-performance computation or rendered as LaTeX.
    One neat idea: "juxtaposition" was an overloadable operator... in fact, two overloadable operators with different precedence. So "a[i,j,k]" is the variable "a" indexed by the tuple "(i,j,k)", while "a [i, j, k]" is "a" multiplied by the array "[i, j, k]" (assuming both those operations are meaningful on whatever type "a" happens to be).

    Screwtape at 2017-07-31T12:47:53Z

  • 2017-07-21T09:17:18Z via Identi.ca Web To: Public CC:

    Having given up on Sphinx, I came across MkDocs which is a similar idea, but simpler and based on Markdown instead of ReStructuredText.

    The resulting docs are a bit more primitive with respect to formatting and structure, but I still get multiple separate files stitched together into a single website, with a whole-site search feature. And it'll require less munging of my existing content, too.

    Claes Wallin (韋嘉誠) likes this.

    Given the idea of using Markdown (whichever version it is; there are so many) Pandoc may also be interesting. It supports many Markdown versions (including its own with some extensions) and can output to many formats.

    Jason Self at 2017-07-21T13:05:46Z

  • 2017-07-21T03:49:55Z via Identi.ca Web To: Public CC:

    I'm writing some documentation, and it started out as a simple README.md as you'd expect... but it's grown and trying to maintain documentation in a single .md is difficult, especially when you need to start making assumptions about how the resulting markdown renderer will auto-linkify headings and such.

    I said "I know, I'll switch to a Real Documentation System, like Sphinx!" And sure enough, splitting documentation across multiple files and getting a table-of-contents and an index all for free is pretty sweet... but Sphinx doesn't make headings into link-targets at all. Which means for all the dozens of times I link between docs, I need to manually put an ID marker in front of every section header.

    That doesn't sound fun at *all*. :(

    Claes Wallin (韋嘉誠) likes this.

  • 2017-07-15T04:59:42Z via Identi.ca Web To: Public CC:

    I really like Identica, but every time there's an unannounced outage for a few days I wonder if maybe I should add "write my own ActivityPub server" to the end of my todo list. :/

    Timo Kankare, AJ Jordan likes this.

    Or just "install my own Pump.io node" =)


    Either way, it couldn't hurt!

    JanKusanagi at 2017-07-15T13:16:25Z

    jxself likes this.

  • 2017-06-29T13:07:05Z via Identi.ca Web To: Public CC:

    When it comes to human-editable config and data files, XML and JSON are human-unfriendly, INI syntax is limiting and unspecified, and YAML has some nice ideas that don't scale up to medium-sized documents, le alone large ones (trust me, I've spent a lot of time wrestling with Ansible playbooks).

    So far, my favourite contender has been TOML (nearly as rich as JSON, much more human-friendly to write) but today I came across a thing called OGDL, the Ordered Graph Definition Language. The data-model is super-minimalist: the basic syntax produces an ordered tree of byte-strings, and there's an optional second pass that interprets some nodes as references back into another part of the tree to make a fully general directed graph. Since the data-model is simple, the syntax is deliciously simple too: write a word on a line, if the word on the next line has a greater indent, it's a child; if it has the same indent, it's a sibling, etc.

    I don't think I'd want to make it my standard config file format yet (for one, there's no Python library for it), but it's something I need to keep in mind for the future.

    Clacke moved to social.heldscal.la and datamost.com, Charles Stanhope likes this.

    Clacke moved to social.heldscal.la and datamost.com shared this.

    OGDL is interesting. It certainly seems promising for descriptions of complex objects that might refer to each other. Although, for a language intended for humans, I find it's definition of a comment a little strange and likely to lead to confusing errors (the grammar also doesn't seem to match the textual description). Also, I wonder why '#=' (more confusion for the comment character) was defined for an arc to a node instead of something like '->'.

    Charles Stanhope at 2017-06-29T14:33:53Z

    They needed a reserved character to begin a comment,  I guess they figured it would be easier to say hash-space begins a comment and hash-equals begins a reference, than to have multiple reserved characters for different purposes.

    On the other hand, I don't recall the spec describing what should happen with hash-followed-by-any-other-character, so that's a potential interoperability hazard, right there.

    Screwtape at 2017-06-30T15:14:34Z

    Claes Wallin (韋嘉誠), Clacke moved to social.heldscal.la and datamost.com, Charles Stanhope likes this.

  • 2017-06-28T03:14:00Z via Identi.ca Web To: Public CC:

    For my own edification, I'm trying to get work done with an X11 port of the Plan 9 editor sam.

    I'm not stressing it particularly hard; I'm just writing documentation so I don't need much more than copy/paste and finding text by regex. Still, I'm already annoyed by the way sam has its own custom window-management system (instead of just opening multiple top-level windows I can manage with my normal window-manager), and its own custom clipboard (Both of those are true to the original Plan 9 version, although the custom-window-management thing is slightly more idiomatic there).

    I keep wondering how difficult it would be to try and bolt structural-regular-expression handling and multiple-cursors onto something like a GTK text-box widget...
  • 2017-06-25T02:16:31Z via Identi.ca Web To: Public CC:

    Somebody on lobste.rs rhetorically asked why anyone should care if the general public finds it difficult to learn to program. After all, we nerds learned well enough without help, and the average Joe doesn't really need an algorithm to pay his rent or buy his groceries.

    My reply:
    People need to know programming for the same reason people need to know arithmetic or how laws get made: because other people already know those things, and many of those other people are quite happy to use that information to exploit people who don’t know those things. Consider how much of an advantage payday loan sharks have over people who haven’t internalised the mechanics of compound interest, or how much of an advantage organisations with professional lobbyists have over other organisations, and compare that to how much of an advantage Google and Facebook have over people who don’t understand data-mining and automated data processing in general.

    People really need to know programming, but it’s the kind of need that’s most obvious in retrospect, when it’s too late to do anything about.

    Claes Wallin (韋嘉誠) likes this.

    Claes Wallin (韋嘉誠), Claes Wallin (韋嘉誠), Claes Wallin (韋嘉誠) shared this.

  • 2017-06-18T00:55:32Z via Identi.ca Web To: Public CC:

    Note to self: if I'm ever making up monsters for a story or game, I should have a metallic icthyoid and refer to it as "the Silverfish, or argentuna".
  • 2017-06-17T01:59:22Z via Identi.ca Web To: Public CC:

    Huzzah, Identica's back!

    Is there any place we can go to find some kind of status information during an outage?

    You can mail admin@e14n.com xD

    JanKusanagi at 2017-06-17T11:22:15Z

  • 2017-06-04T05:44:09Z via Identi.ca Web To: Public CC:

    Yesterday on Hacker News, I read an article that claimed to be an inside perspective on What Really Happened With Windows Vista. It's pretty interesting, but there was one idea that I hadn't previously encountered. A given software implementation balances functionality against the resources (time, storage, etc.) available, but both user expectations and hardware resources change over time. The article mentions two different responses to such changes:

    • Hardware Supports Software: software is always complex and difficult, so if we can add complexity to the platform (OS, compiler, runtime) in a way that makes applications simpler, more reliable, more maintainable with the same level of functionality, we should. If that means spending extra hardware resources on computational overhead like runtime checks and managed code, that's a trade worth making. The article claims this was Microsoft's mindset at the beginning of Vista's development.
    • Software Supports Hardware: people buy hardware to fulfil some particular function, but while some software is necessary to make it work, too much software just slows everything down. Therefore, software should be restricted to what's necessary to provide functionality, and extra hardware resources should mean everything just runs better. The article claims this was the mindset behind Apple's iOS.

    Both viewpoints have merit, but they're clearly incompatible. Now that they've been pointed out, I suspect a lot of the technical discussions I've participated in over the years were at least partly based on "Hardware Supports Software" people looking at a project based on "Software Supports Hardware" ideals and boggling, or vice versa. For example, I reckon the systemd and GNOME teams are squarely in the Hardware Supports Software camp, while Software Support Hardware presumably hosts the suckless guys, and anybody who owns an Arduino.

    joeyh likes this.

  • 2017-05-26T14:31:09Z via Identi.ca Web To: Public CC:

    For a Python script parsing command-line arguments, it seems there's only a few candidates:
    • "optparse" in the standard library, which is quite limited, and besides which was removed in Python 3
    • "argparse" in the standard library, which is pretty flexible, but which produces weird, un-intuitive "--help" output if you have subcommands.
    • "docopt", which generates a parser from "--help" output, but traditional "--help" output glosses over a lot of details that I want to specify, like which options are valid with which commands.
    • "click", which seems to support all the features I need and produce the pretty output I want, but it's a framework that takes over your program rather than a library you call into, and I find that kind of API endlessly frustrating.
    This makes me a sad panda.
    Argparse is definitely not great with subcommands, but that's the one I've settled on. I would like to try click sometime, but the framework thing is a barrier. I also would like to try Google's "fire" at some point to see where it might be appropriate to use: https://github.com/google/python-fire

    Charles Stanhope at 2017-05-26T17:19:48Z

    Oooh, I think I'd heard about Fire, but I'd forgotten. Thanks for reminding me!

    Screwtape at 2017-05-27T01:26:49Z

  • 2017-05-23T04:19:53Z via Identi.ca Web To: Public CC:

    I decided to write up the instructions for combining GNOME Flashback and i3 that I mentioned the other day, and in the process I figured out how to make them simpler, and not require root access. I'm pretty pleased with that:


    It's pretty nice to have fast, space-efficient i3 on my tiny laptop screen, and have the special screen-brightness and audio-volume keys Just Work.
    Nice! Thank you for taking the time to document and share! :)

    Charles Stanhope at 2017-05-23T12:16:50Z

    Thanks for encouraging me. :)

    Screwtape at 2017-05-23T12:24:54Z

    Charles Stanhope likes this.

  • 2017-05-22T10:12:40Z via Identi.ca Web To: Public CC:

    Writing technical documentation, trying not to start every single paragraph with "However" or "Unfortunately" or "Luckily" or "Previously" or "Therefore".
  • 2017-05-21T05:58:38Z via Identi.ca Web To: Public CC:

    The weak misanthropic principle: "humans can be hard to get along with"

    The strong misanthropic principle: "humans are fundamentally horrible"