Archive

Archive for the ‘Technology’ Category

Software Testing

One of the most important lessons I began to learn in my career as a Computer Science student was the importance of software tests. (I say “began” because I still haven’t learned to habitually write tests first.) The past couple of weeks have reminded me of this, so I’d like to talk about it today. Read more…

Desktop versions of web applications: Apparently unwritten progams

In recent years, there’s been a major trend toward moving computer applications “into the browser”—instead of using a desktop email client that accesses a mail server over a well-documented protocol, we use “webmail.” Instead of discussions happening over email or news or on “bulletin board” servers that can be accessed with desktop clients via well-documented protocols, we have a plethora of “web forums” and blogs using various customized versions of a handful of “forum server” and “blog server” packages, to say nothing of Facebook and other social networks. And all this places increasing demands on web browsers, which were originally designed to just let users browse and navigate information formatted as hypertext.

Because web browsers—and, more importantly, the hardware they run on—don’t keep up with the load “web-apps” impose very well, this trend should be reversed. Web application developers should eithe provide desktop clients for their services, or at least make it simple for others to do so by exposing the functionality in well-documented, stable, protocols and APIs. But because most web-app authors don’t do this, desktop versions of the web-apps I use simply don’t exist, like the other “unwritten programs” I’ve written about. Read more…

Imperial Robo Cards: A planned project

Earlier this week I described Imperial Robo Cards, a popular collectible card game in the world of the Shine Cycle. But IRCs are not just a curious bit of worldbuilding; they started as a card game I began to design as a child, and they’re a game I’d like to create, properly, sometime in the near future. Read more…

Curfew Enforcement: An (apparently) unwritten program

January 14, 2012 1 comment

Over the past several years, I’ve discovered that I work best when I rise early in the morning after a full night’s sleep, but that, left to myself, I tend to “work” long into the night (usually without getting much done). So getting to bed at a reasonable hour takes a large amount of willpower, at a time when my supply of willpower is most depleted. You can imagine the problems this combination causes.

A couple of years ago, I had the strange problem that my laptop’s connection to the local wireless network would (more or less reliably) disconnect at about ten o’clock each evening and refuse to reconnect until about nine the following morning. This grew annoying, but until I discovered and worked around the cause (and then bought a new laptop), I was (for me) tremendously productive—if not quite as productive as I was back before I had a regular Internet connection. Read more…

Educational Games: An Unserved Market

I’ve been thinking, recently, about the computer games (“educational names” is what I suppose the genre is called now) I played in my childhood. Back then we had a IBM 286 PC with a menu system on top of DOS, which we eventually upgraded to Windows 3.1—by the time we upgraded to Windows 95, I had become tired of all of the “educational games” we had, and preferred more “grown-up” games (card games, strategy games, puzzle games, etc.)—though even now I’m not much good at most computer games.

When I thought of those games I had known and loved in my childhood, I went looking for them, and for equivalents. The Learning Company, which made several of the games I remember (Midnight Rescue, Treasure Mountain, Treasure MathStorm, Reader Rabbit III, Gizmos & Gadgets—though some of those I played only at school or friends’ houses, and one only much later), is still around and apparently still making games. I suspect that the companies that made the simpler, less polished games (which were for all that just as fun and, for a budding academic, often less tedious) have all gone out of business by now. But on the “equivalents” side of the field: TLC is apparently still making games, and there are a few other big names, but my impression that all the effort is going toward an audience of older children, who would be bored by the games I’m thinking of. And all the free software games I’ve found in my cursory search are in only a very few categories: learning basic computer skills (e.g. TuxPaint), beginning to learn to read, and … one other category I can’t think of right now. Furthermore, I was surprised to find no free imitations of the classic games I remember.

So it seems to me there’s a possibly untapped market here, or at the very least a niche of “the free operating system” that’s missing: basic educational programs, to help kids learn and drill the essential skills that they’ll need for the rest of their lives. Things like counting, recognizing patterns, basic arithmetic, dealing with money, fractions, elementary reading, basic science, some history … and the list goes on, and what we need is not “one program to fit them all”, but games customized in design to best fit the skills they’re trying to develop. (This is not to say that we shouldn’t create a library and make each game a thin veneer over that library, but the engine, or the library, is not what’s missing—it’s the games that use that library or engine.)

For now, I’m putting “educational programs” on my long and growing list of programming projects I’d like to get to someday, along with the mathom game, reimplementations of some old libraries we happen to have libraries for (more on that in a later post sometime), and so on. But if I could find a partner, or some collaborators, to fill the gaps in my expertise (art, visual design, some low-level stuff) and check my work, I could move this up in the queue and start working on such a program very soon. Any takers? Any ideas?

Universal Source-Based Package Manager: An Apparently Unwritten Program

Since soon after I arrived at college, I’ve used Gentoo GNU/Linux as my primary operating system. I’ve tried other distributions now and then (I started with Red Hat 6.1 and a Slackware derivative, then tried what was then called Mandrake …) but always find myself needing Gentoo’s flexible init scripts or powerful system administration commands.

However, there’s some software that just isn’t available on Gentoo, and for which writing an ebuild would be very complicated and challenging—but it’s in Debian or Red Hat or a derivative, and built there from source. And while I love the power and flexibility of Portage, there are some features of other build systems that I wish it had. (For example, SourceMage and Lunar Linux do all the build-time configuration up front by asking you questions, and automatically add anything that needs to be rebuilt to the queue.)

This brings me to our next program that (as far as I know) doesn’t exist, but should: a Universal Source-Based Package Manager. It would be able to take the input of any source-based distribution—Gentoo ebuilds, SourceMage “spells”, Lunar’s “Moonbase” modules, Debian rules files, Source RPMS, etc., etc.—and build and install the package. (The user might have to do some configuration to get it to handle differences in the way distributions name packages, though there are several projects that might help in automating this, including distromatch, PackageMap, and whohas.) And it should allow the user to customize the build as much as the source formats do, or (in the case of binary-building formats like Debian rules and SRPMs) more. Ideally, it would let the user decide whether to do configuration via configuration file tuning a la Gentoo, or by interactive questions a la SourceMage or Lunar.

Does such a program exist yet? What other features should it have? And how might one go about writing it?

Mathoms and Games

When I was growing up, before we got Internet access (i.e. before my junior year of high school or so), my family and I spent a lot of time on Grex, an Ann Arbor-based BBS and free shell provider. At the time, one of the games (written by a founding member of the system, but which has since vanished) was a “mathom” program.

A mathom, in Tolkien’s Lord of the Rings, is an item that’s rather like a white elephant—it’s valuable, most likely old, and probably unique, but not by any means useful—at least to you, anymore. (Bilbo’s mithril shirt was a mathom.) It was almost certainly given to you by someone important (or important to you), and likely has a long and distinguished history, so you can’t just get rid of it. And it’d be a shame to pack it away in your attic and forget about it. So, if you can’t set it in a place of honor or put it on display, the only thing to do with a mathom is to give it away to someone else.

And that was the premise of this program (hardly a game, really …): you created mathoms and gave them away. If you received a mathom, you could keep it or, now or eventually, give it away to someone else. Especially for a literate and imaginative middle school student, this was a very diverting pastime, and I remember it fondly. But the system has changed hardware twice since then, and been ported from operating system to operating system, and somewhere along the line the mathom program was lost.

A couple of years ago, soon after Facebook created its applications platform, I thought to myself, “Surely someone’s created a mathom game for Facebook!” After all, this sort of thing is ideal for a social platform, and many of the most popular games include sort-of-similar mechanics. But no, my search came up empty.

So now I’ve added such a program to my list of projects to get to one day. (My initial brainstorming of use-cases was on the pad I mislaid a few weeks ago, the same pad as yesterday’s poem. But I can do more thinking when I get around to it.) I think that before the time comes to turn part of Strategic Primer into a social-network or mobile game, I’ll do this to get my head around the development environment, model, and ecosystem.

But I’d still like your thoughts now. Comments?

File Formats: Readable vs. Convenient

If you want to send me a document—a story, poem, or essay; comments on some of my work; a circular letter; your resume (for whatever strange reason!); or pretty much anything else (though I’m restricting this discussion to word processor documents and spreadsheets)—there are a few formats I would like (and, depending on how I feel about the document in question, love or be delighted might not be too strong a phrase) to receive it in, several that I can easily enough read it in, and a few that I can if necessary read it in. Today, I’d like to explain which formats go in which categories, why.

Preferred formats

These are the formats I would be delighted to receive. (Given the scarcity of attachments in these formats, do not be surprised if I write an effusively-thankful reply to an email with such an attachment.)

  • Plain text, optionally with some sort of unobtrusive markup.
  • Readable (i.e. not word-processor-generated) HTML.
  • For spreadsheets, the venerable (and quite old) SC spreadsheet format. (But unless you’re using SC or XSpread, don’t bother.)

Easily-Enough-Readable Formats

These are formats that I can read easily enough, but that are somewhat annoying or inconvenient given my normal workflow; they also tend to be much larger than my preferred formats.

  • Any of the OpenDocument formats, which are the native formats of OpenOffice, LibreOffice, et al.
  • Obfuscated HTML.
  • The native formats of the GNOME Office suite.
  • PDF files, so long as you can copy the actual text. (Some PDF documents use vector graphics to draw the text.)
  • TeX, DocBook, or similar formats.

Formats to Use If All Else Fails

These formats are quite annoying, rather inconvenient, or otherwise objectionable. Other than Microsoft Office formats, these are generally formats from word processors I’ve used in the past, whose files I now wish I’d saved as text instead because they’re such a pain to read now.

  • Microsoft Office format files, particularly since Office 2007. (Office XML—.docx—is worse than the old format.)
  • Microsoft Works format.
  • WordPerfect format (though the older the better, to a point …)

Explanation

Most of the time, I use a standard text editor for editing documents, adding simple markup if I need to designate formatting. (Margins, line spacing, fonts, and the like are distractions at best.) If I need to produce or read one of my non-preferred formats, I open my graphical word processor, OpenOffice, or if formatting is not essential I rely on command-line tools (Linux intermediate and advanced users: I’m talking about lessopen) to convert them to text. OpenOffice is bloated and resource-intensive, and doesn’t integrate well with the rest of my work (since I do most of my work in tabs of a terminal emulator).

Also, I try to keep as much of my work as I can under version control. Binary formats—anything except text and uncompressed markup languages—don’t mix well with version control—and this is worse than you might expect because they’re so much bigger than equivalent plain-text files.

Conclusion

  • If you have only the faintest glimmer of what I’m talking about, or you’re sending the file to lots of people who aren’t like me: Just send the file. If I can’t make it work, I’ll talk you through producing something I can read.
  • If you have a document where relatively-complex formatting is important or the document in question is a spreadsheet: I suggest OpenDocument (i.e. OpenOffice) format.
  • If your text is all that’s important: send me the text; paste it into the email if you must.
  • If you’re using the collaborative-editing, comment/review, or version tracking features in what you want me to see: Don’t. (Unless you’re using OpenOffice as your primary word processor—and even then reconsider.) These features aren’t always compatible even between different versions of the same program; they are unlikely to work properly with a different program relying on a reverse-engineered specification for a competitor’s format. For commenting on specific parts of a text document, you can simply quote (put (right-angle-bracket, or greater-than-sign) marks in front of each line that you’re quoting) the relevant parts of the document, then write your comments unquoted below. (Just like standard Net etiquette says you’re supposed to do in email.)

Future History: Computing

As one might expect—since my degree is in computer science—one of the minor areas (sub-themes, if you will) that I touch on occasionally in the Shine Cycle, my fantasy series-in-preparation, is alternate-universe computing. I like to speculate as to how computers and the ecosystem of ideas around them might develop if a few dozen people from our generation, including a handful with some trained insight into the inner workings of the technology, get dropped into a culture for whom “the Internet” was something to read about in yearly diplomatic or intelligence briefings, if that. And how that development would change symbiotically with the use of applied metaphysics.

But I’ll write more about that later. Today I’d like to talk about how, for the purposes of that part of the Shine Cycle which are set in our own future, I project computing will develop in our world over the next several centuries, and what sort of impact it will have. Read more…

Persistent sessions: an apparently unwritten program

When I “shut down” my computer—any computer&mash;at the end of the day, or to go off on an errand, I’m usually actually “suspending” or “hibernating” it. I run like this—accumulating disk corruption and, if I suspend rather than hibernating (because hibernation doesn’t work on my current laptop), wasting power—for weeks or months on end until either an upgrade forces me to reboot or, inevitably, something crashes. (On my current laptop, that something is usually something in the wireless networking stack; I’m not entirely sure what. A “crash” doesn’t necessarily brick the machine until I power-cycle it, but at least renders it mostly unusable without a reboot.) Or (on my desktop), because either it overheated or the power flickered (despite the UPS!), it simply turns itself off.

I go to such great lengths to avoid rebooting, and am so very frustrated every time a system crashes, hangs, or loses power because the software doesn’t support proper, persistent sessions. (I’m picking on Linux here, which is what I use primarily, but Windows is no better.) I always have well over a dozen terminals (between a screen session and Konsole tabs), each in a different directory, many with a Vim session open, in addition to two browsers and an IM client. But the most that the best “session saving” features of any current desktop environment or window manager can do is recognize that I had a Konsole window open, or perhaps how many tabs it had open and at best what directory each was in.

This is not good enough. The mere directory isn’t usually enough for me to remember what I was doing there. And this really shouldn’t be up to the desktop environment or window manager, because session saving should extend to terminal sessions that don’t involve a GUI at all. If my computer crashes, or if I have to reboot, I should be able to boot it and each terminal, once I log in, back where I was, in the same milieu—editors open to the same files in the same places, a little of the scrollback buffer visible to show what I was doing.

My current workaround is a shell script that I source in every terminal, that sets up my environment (changes directory and then prints an explanatory message) based on which terminal it was called from. But I have to maintain this script, and I have to anticipate what I’m going to want to be doing. This isn’t good enough; it should Just Work.

Have I missed something that does what I want? This shouldn’t be all that hard

 

I’ve also written other essays about (apparently) unwritten programs.

Follow

Get every new post delivered to your Inbox.

Join 42 other followers