Ultimate unit of time

Everyone knows Y2K (or else you wouldn’t be reading past this parentesis), but there’s also Y2K38 (32-bit Unix timestamps run out) and the Y292B277M026K596 problem. Why not get rid of these problems through the power of science?

The Planck time, at roughly 5.39106×10-44 seconds, is the smallest time measurement that will ever be possible. The Universe is, at current reckoning, about 13.75 ± 0.11 billion years. Seems to me we could put these facts together, and create the last reckoning our computers will ever need. With a bit of generous rounding, we get to around 2.6×1053 Planck time units of time until now. Converting to binary, that’s 177 bits. But what about the future? Well, since computers generally work best when given data in sizes equal to a power of two, we might as well round up to the nearest – 256 – And have plenty of time. In fact, 256 bits (less than it takes to store your postal address) would be sufficient to store time units until way, way beyond the existence of the human race, or indeed, of the fundamental particles of the universe.

Fix Git repository after Subversion conversion

After converting a Git repository from Subversion with svn2git, all was well. At least until I wanted to squash some of the oldest commits with the excellent interactive rebase. Full of fail, I realized that I might have to do some cleanup before going on such a bold expedition. Here’s a couple tricks for “post-processing” a converted repository.

  1. Make a backup! Ideally, do this work on a clone of the original repository, then use a tool like Meld (or simply diff -r repo_backup new_repo) to check that the resulting files are the same as before.
  2. Remove empty commits: git filter-branch --commit-filter 'if [ z$1 = z`git rev-parse $3^{tree}` ]; then skip_commit "$@"; else git commit-tree "$@"; fi' "$@"
  3. Garbage collect and prune: git gc --prune
  4. Start interactive rebase from the first commit: git rebase -i $(git log --format=%H | tail -1)
  5. Squash all commits with empty messages. These are shown as multiple commit IDs on the same line with a space and > between them, like this:
    pick 1111111 >2222222 >3333333 Message

    Just split these up and remove the commits, like this:

    fixup 1111111 nothing
    fixup 2222222 nothing
    pick 3333333 Message

    In Vim, you can do this by repeating the following command until it reports no hits: :%s/^pick \([a-f0-9]\{7\}\) >\([a-f0-9]\{7\}\)/fixup \1 nothing\rpick \2/g

  6. Exit the editor, and the rebase should complete on its own.

Warning, as always: YMMV and RTFM.

Regarding finger scan as part of IELTS identity verification

Verbatim email to ielts@britishcouncil.ch:

Dear British Council,

While going over emails related to my taking of the IELTS test, I came across the disturbing news that you are in the process of implementing a mandatory scheme of finger scanning for candidates.

According to your “IELTS candidate identity verification” page “[T]est centres in these countries will advise candidates before they register that finger scanning is in place.” I have received no information to that effect. Please advise as to whether finger scanning is (or will be) mandatory in Switzerland in 2012. If it is (or will be) mandatory, I shall on the grounds of basic decency have to refuse to take the test with your organization.

A disappointed customer

Got a reply the next morning:

Dear Mr. Engmark,

Thank you for sharing your concerns with us. New security measures (finger scanning and / or photography taken on the day) are in place in all the IELTS exam centres to deter candidates who ask somebody else to take the exam for them, hoping to get a higher score.

While we are happy that in Switzerland the number of attempted identity frauds has been insignificant, we have to be prepared and act in line with the global standards. Therefore we have already introduced the test day photography (which means that a photo of each candidate is taken on the day of the test, and this photo will be printed on the Test Report Form). We have not introduced the finger scanning, and do not have plans to do so.

I hope this information will be of help in your decision of taking IELTS with the British Council in Switzerland. Please see further details on registration and available practice materials on http://www.britishcouncil.ch.

Thank you again and have a great week ahead!

Best regards,
[redacted] | Exams Services Manager | British Council Switzerland

And my response:

Thank you very much for the quick and informative response; I will attend.

A relieved customer

I guess it might have more to do with the country in which the test is done than the British Council themselves. Good to know.

Mein Kampf at OSL

No, this is not some tastelessly titled travel story. During a routine book store stop at Oslo Airport Gardermoen, I felt surprised and slightly uncomfortable seeing Mein Kampf for sale. Two paperback copies, side by side, both with that familiar crumpled back caused by heavyhanded customers checking out random pages. But it’s the sign of a properly civilized society to trust that people will read such a book knowing its significance, and act accordingly. For me the significance is simply this: Anyone who follows a person or book without question is a dangerous, untrustworthy fool.

Not my cup of tea to put it mildly, but a good sign. And Bill Bryson’s At Home is turning out excellent.