The importance of printable objects

I have a small defect in the Python code I produce: I rarely botherto make my classes printable or to give them a repr(). Most of theclasses will never be printed, and the default repr value is goodenough to distinguish two instances from each other.

But this is a mistake, nicely illustrated by my grump about assert'sweakness as a debugging tool . Objects having a usefulstring value makes it much easier to dump out information about thestate of things when a problem comes up.


A fundamental problem with challenge/response anti-spam systems

A fundamental problem with CR is that it implicitly assumes that yourcorrespondent wants you to read their email more than you do. Just lookat who's doing the work: your correspondents are doing work so that youdon't have to.

(Of course, observe that the people for whom this is the most true are the spammers.)

When this is not true, when you want to read the mail more than thesender wants you to, is exactly where CR systems break down. You mightthink


買甚麼好?

我想買一份生日禮物俾自己,

但係... 買咩好呢?







唔好叫我買個男人返o黎

Link: Pumas on Hoverbikes

Pumas on Hoverbikes is aboutmanaging system administrators, and it's funny. Here's a somewhatout of context quote:

This is because managers are usually people who proved that they werehandy with a chaingun and were thus rewarded by having their thumbscut off and their weapons handed to some punk college hire.

From this you should be able to figure out if you want toread the rest. There's other articles too, like Suck Factor , which is where I first droppedinto the site.

(


The quest for the mythical C.UTF-8 locale

Recently, Pete Zaitcev wrote in passing :

Now if only someone designed a UTF-8 locale which did not screwthe ordering files in ls output...

What he said. I've come to realize that what I want what I'll call the' C.UTF-8 ' locale: all of the old-fashioned Unix non-locale behavior,but with non-ASCII characters encoded in UTF-8. I don't mind UTF-8 toomuch and it's clearly the


春風秋雨 vs 天水‧圍城

看到 小奧評克勤新碟 ,他說:

忽然想到如果換了是《張學友演奏廳》或《陳奕迅演奏廳》又會是如何的光景?《天水.圍城》會不會添上震撼三分,《Paris Hilton》會不會忽爾性感?

事實上,在我聽《天水‧圍城》的時候,聯想起正正


Link: Unicode Spaces

Presented without comment, the 18 spaces of Unicode .

(From Sam Ruby .)


如何說話

文明單位:英文
嘉賓:蔡寶瓊

我聽過蔡寶瓊講話並不是很多次,每次都佩服得五體投地。做節目時也忍不住趴在桌上露出「超勁啊真係超勁啊」的表情;她有點訝異,但依然以那種我覺得無比理想的俐落節奏(和完整句子)流暢

近日

9月開始返工
只是一份合約工
工作量不算太多
不過我有另些兼職同時進行
也不算太忙
但少了一點拍拖時間吧

而最痛苦的莫過於睡眠時間不足
睡眠時間不足唔係因為工作過忙
而是在我9月開工至今
在我未起身返工前
屋企外就有地盤

HTML character sets

I started with a simple question that was vaguely orbiting in the backof my mind: are HTML numeric character entities always in Unicode,regardless of the character set of the HTML web page? The answer isyes, and that I was asking a misleading question.

Despite being called 'charset' in HTTP headers and META declarations,what you are declaring is actually the web page's character encoding,not its character set. HTML is specified as always being in the Unicodecharacter set, although the encoding of characters