GNU Object Model Environment: Building a full, user-friendly desktop for Unix operating systems, based entirely on free software. Release notes for Gnome 2.20, the latest version.
dear dave and probably others: youre talking about not having the time to read that book, but it seems that you have some time to open a web browser, to log in into your blog, to create that new post, search the book on amazon and then actually write a few lines on it. then you will spend some time on reading the comments and maybe spend a few more minutes on doing some replies.
now, think about other useless stuff youre doing. please also pay attention about the definition of useless: listening music, drinking a beer with some friends, cooking for people, sleeping, having fun with cheese ( ;) ) is _not_ useless, at least it shouldnt. however staring on the computer screen or browsing the web for new wallpapers probably is. how much time are you spending on nothing?
its amazing how much more time you will have if you try to keep an eye on yourself, and for sure you will be able to tag your book with the "already read"-tag. my opinion, it works for me.
We’ve now cleared away the set from another WHP production, this time of Abigail’s Party (photos!). I can’t say it was the best play I’ve ever done; it was a departure from the normal type of comedy play we do, and although change is nice, I wouldn’t want to do another like this. I did not really find it funny, and while the five actors were doing phenomenally on stage, the script itself was what I didn’t like. That said, the audiences on all three nights appeared to really enjoy it, so perhaps I’m being too critical.
I was quite disappointed with how the lighting came out, and that’s entirely my fault. Having set it all up and gone through the dress rehearsal, I adjusted it to cover the few dark spots there were, and thought that was the end of it. However, by the time we were half-way through the first performance it was obvious to me that there were still some not-inconsiderable dark spots in a few areas which bugged me throughout. They weren’t bad enough for the audience to notice (as far as I could tell), but were in no way dismissable.
In GNOME news, I’ve been unable to do anything except bug triaging for the past few weeks, due to a combination of exam revision and this play. Once my exams are over (in another couple of weeks), I hope to be back to working on Totem, ready for a GIO-filled 2.24 release.
After last year's GSoC project I decided to write a DVB Manager this year.
Checkout the page at Google about details. My mentor is Zaheer Abbas Merali.
Thanks a lot GNOME for accepting me again.
I'm going to do status reports regularly.
For some reason, Facebook's presence bar makes epiphany really slow during scrolling. If you, like me, don't use the presence bar, add this to your personalized style sheet:
@-moz-document domain(www.facebook.com) {
body #presence { display: none; }
}
This will hide the presence bar and bring smoothness back.
Firstly, hello to all that are reading on Planet Gnome as this will be my first post that has been syndicated there. And by way of introduction, I’m a 23 year old student in my final year at York University studying Computer Science and Maths. I’m working on bug 48004 to implement individual workspace wallpapers. (For those that are interested you can find my previous posts at http://gsocblog.jsharpe.net/.)
I’ve spent the last couple of weeks finishing up my masters project, and gave my presentation on that last Friday. Its good to get it all out of the way, although my supervisor has suggested submitting my project to the S+SSPR conference which means I need to edit my paper by the end of the month. I also have a computer graphics assignment to complete and three exams to revise for before the official start of GSOC on 26th May, so quite a bit to do before then. I suspect I’ll be juggling my time between uni and GSOC up till the 10th June which is the date of my last exam at uni.
In the mean time I’ve been looking through the code that I’m going to be working on; the desktop wallpaper code seems to be spread across numerous modules: gnome-desktop, gnome-control-center, libeel, libwnck and libgnomeui. Initially I’ll be working on getting the backend part working for which the following criteria need to be fulfilled:
I’ve also been hacking a little at jhbuild; I’ve setup jhbuild to use git-svn in place of svn but it’s handling of externals is painful! I’ve put in a hack that checks the current svn revision of the git-svn tree before and after the rebase, and conditionally updates the externals only if the svn revision version has changed. Now this works fine if the svn:external is for a given revision number in the external repository, but if its not then we still need to do an update because the external may have changed whilst the current repository hasn’t. This kind of breaks the notion of a revision number in svn as it means that a revision in the repository is dependent upon the state of an external repository i.e. it will change over time! Not a good thing for repeatability in the future. I’m thinking about storing some metadata within the git-svn checkout dir relating to the location of externals(if any) as a way of avoiding walking the whole svn directory structure which is particularly slow! The alternative is to implement the externals as git submodules, as noted in a fixme within the code. There’s also a number of other features missing from the git-svn code too that I may roll patches for:
Over the past week, I've been spending some time hacking on Evolution again because of my frustration with the current IMAP backend. This got me to wondering... why hasn't anyone stepped up to the plate and rewritten Evolution's IMAP code yet?
As you may have gathered from previous entries, I've recently become interested in programming languages again.
I'm almost done (though skimming some parts) with my copy of the aforementioned Ruby book. and though I haven't done any substantial Ruby programming (just playing around in jirb while reading), I think I have a good idea now why so many people love the language.
Most of my real code over the last number of years has been in C, Java, and Python, and I know those languages and their runtime libraries pretty well, but reading the Ruby book I was struck by how really useful closures can be in an Algol-family language (i.e. not Lisp). Well, Ruby calls them "blocks" and has infrastructure on top in the form of yield, etc., but that's fundamentally what they are. C/Java/Python all lack them (no, Python's single-line lambdas are too restrictive to count). 
Closures...environment, get it?
Closures are incredibly powerful, in fact you might say they're the ultimate language construct. Neal Gafter has a good description of the kinds of things you can do with them, going from a language that doesn't currently have them.
While I was thinking about this blog entry, I reread one of Steve Yegge's great blog posts, and decided to look up more about his reference to the author of a design pattern book "leaving Java to go to Ruby". After going to Martin's home page, I found on his wiki he has a good entry which is pretty close to what I wanted to talk about. That is basically: it makes sense for large software systems to have multiple layers in different languages.
Now, if you're thinking "Wow, that's obvious", that's good; but there is more to the story here. So let's look at some rationales. If your app is large enough, you probably have parts which need to be fast. And you probably have other parts which cry out for a domain-specific language.
So for speed, you'll want a lower layer which is usually characterized by manifest typing and direct vtable function dispatch. Read: C++/Java/C#.
But it makes sense often to have a higher layer which is agile. It is better for the parts of your program which change rapidly - this could be user interface bits you're prototyping, or rapidly creating test cases. This layer is usually characterized by implicit typing (possibly with type inference), metaprogramming capabilities, and (ideally) good integration with the lower level language. Read: Groovy,JavaScript,Python,Ruby
There is a lot of software out there split in exactly this way; in fact, you're almost certainly reading this blog entry in one of them, Firefox, where the answer is C++ and JavaScript. A lot of computer games are built in this way too - for Civilization 4, the answer is C++ and Python, and for World of Warcraft it's C++ and Lua. If you're familiar with Java, just think about JSP and Ant - they're really DSLs. If you mostly know Python or Ruby, think about how much of the underlying platform is actually written in C/Java/.NET.
So it's fairly easy to dismiss anyone who says something like "everything must be written in language X", for values of X like C,Ruby,Python,Java. Which reminds me to say: Eclipse really needs to embrace Eclipse Monkey.

So we accept that it makes sense to have multiple languages with different characteristics. One important issue then becomes - how similar are our two different layers? Taking the example of C++ and Python as in Civilization 4. The gap is enormous. C++ containers are not the same as Python containers. C++ strings are not the same as Python strings. C++ objects and Python objects are wildly different. The answer to this problem is to create a special glue layer; in Mozilla, it's called XPCOM. In GNOME, it's called pygobject. These layers are very painful to create and maintain.
An interesting question is - what if our two languages shared more? Do we really need to have separate container types just to get agility and dynamism? The answer turns out to be - no, which we'll get to in a minute. As we know, the fact that there are a lot of things that every modern language shares lower level components (like garbage collection, JIT compilation) led Microsoft to brand .NET as a multi-language runtime (as an aside, plenty of languages ran on the JVM long before .NET was created; for example Kawa, which dates to 1996). Now here's the thing, though. Running on .NET does not make Python objects same as .NET objects, nor does it make their containers the same.
Let's briefly take a look at what a Python object is. It's a fairly illustrative example of just how different languages can be. In Python, every object instance is by default a dictionary (hash table), with data stored in the __dict__ member. Every property lookup or method call has to in general traverse a chain of hash table lookups. At any point, some other code can come along and add a new entry in an object's dictionary:
#!/usr/bin/python
class Test(object):
def __init__(self, a):
self.a = a
t = Test("hello")
t.b = 42
print t.b
Supporting this level of dynamism is expensive, both in time and space, again because every object instance carries along a mutable hash table under the covers. It means you can't share very much between processes. It makes multi-threading much slower because everything has to be synchronized on that dictionary. Besides being expensive, it's almost never what you actually want, at least by default. You usually want t.b to be an error. This is by far my biggest issue with Python. In fairness to Python, it predates almost every other language discussed here.
Languages are clearly stealing things from each other, and evolving together. In the Ruby book they often mention how certain parts were taken from other languages. Java and C# are stealing ideas from each other. ECMAScript 4 is clearly rebuilding itself on a more JVM/.NET like class model.
What I've been looking at lately is a new dynamic language that has clearly stolen a lot of the good ideas from Ruby and Python, but is a lot more "native" to a modern runtime (in this case, the JVM): Groovy.
#!/usr/bin/env groovy
class Test {
String a
}
def t = new Test(a: "hello")
t.b = 42
println b
This results in an exception about a missing b, because its idea of a class is exactly the same as the underlying JVM platform, where objects are much more static by default (this is also true of .NET). Note we can even declare types if we like (or we can just use def). I really like how default constructors work - it's even less typing than both Python and Ruby! It has useful closures, regular expression and hash table literals. Pretty cool. For a more complex example, here's an example of a fairly typical scripting task of log file processing I wrote a few days ago. I'm fairly sold so far, but there is still more to learn. I spent a bit of spare time poking at getting it packaged, but ran into some Maven bootstrapping issues.
One random link: An awesome feature of Python is Generators, and if you aren't familiar with them and think of yourself as a "systems programmer", check out this very good slide set.
Second to last: some recent additions to my Google Reader feed: Charles Oliver Nutter, John Rose, Lambda the Ultimate.
As an aside that's not directly language related, but also new to my feed list is Why, who is like a great artist-programmer churning out amazing works like Shoes. Does anyone else have the feeling that for Why all of these code projects are just what he does in his idle time, and in the next few years he'll emerge from his underground hideout with an army of giant robots and take over the earth?
I’m looking for a new cell phone, which ought to be usable, syncable with Linux, and cheap. AFAIK, Nokia phones are the most usable among the cheap cell phones, so that’s where I focused my queries. The Nokia 2630, 2660 and 2760 models seem very nice, but they are not officially supported by gnokii or openobex. I found a video of Nokia 2660 being accessed via bluetooth (see also part 2), but I need to know if the phonebook can be synced. Did you ever sync any Nokia 2xxx phonebook using with free software?
The ever wonderful John Resig finally posted his totally awesome processing.js code to the web. If you haven’t seen it, you should go take a look. The Wired Compiler blog said “…this might be the most impressive thing we’ve ever seen.” And I agree, but probably not for the same reasons that they cite.
For a long time we’ve seen a niche on the web being filled by proprietary solutions. So-called rich internet graphics have long been the domain of Flash, before that Java (with limited success), ActiveX and now Microsoft is trying to jam Silverlight onto the world. However, each of these technologies suffers from one fatal flaw: they are, as a friend often described, deeply opaque. If you’re a developer for one of these technologies you’re on your own. You have to engage in a huge amount of training, the tools are often expensive or are difficult to use and then you are locked into a very specific platform. The bar for entry as a creator is very high. I think that Brendan would not mind me using his words to describe these technologies: Ivory Towers.
But the web is different. I’ve recently taken to describe the web as the world’s largest open source project because of its inherent transparency. Someone else doing something really interesting? Take a look at the source and copy it. Improve on it. Share it with others. As a developer for the web you aren’t alone. You have the work of thousands of others to draw upon. And the bar for entry is still about as low as you can get: a text editor. The web is smothered with information on how to develop for the web from the simplest HTML to advanced AJAX including everything from the front end to back end server work. It’s a highly democratized process, one that anyone can invest in and learn with no barriers for entry.
So back to processing.js. What John has done (in his spare time!) is to start to expose the capabilities of what we’ve been slowly adding to the platform of the web and give people a way to start to explore what we can really do. Canvas is here and it works. Video and audio have already landed in a couple of other browsers and we’ll have it soon enough. And each of them is exposed in the lingua franca of the web: transparent declarative markup connected by simple interactive scripts that are distributed as source.
We’re already starting to see the results. John released his code on Thursday. By Friday, someone had already duplicated the processing.js environment as a XUL program and someone else already created an editor where you can try out processing scripts directly on the web. That’s in one day after the code was posted on the web.
Just imagine for a second if those sites let people share and display neat little graphical widgets with source where people can try out different objects and learn from each other’s source code. Easy to drop in graphical interactive elements into other sites with the same transparency and zero-barrier to learning we’ve seen from the rest of the web. Think about how fast that stuff might spread on the web, how we might end up with people sharing and learning together and how much better the experience on the web might be in the end. That iterative process is one that needs starting points and what John has done is give us a great starting point.
So the world is changing. And changing quickly. The web is going to win, filling the market niche where Flash and other similar technologies found their hold. And John’s little project can hopefully act as a great catalyst to take us there. Thanks, John!

Interspecies cooperation by Barry Rogge. License: ![]()
For those interested in some of my previous writings on intrinsic motivation, this survey paper by Simon Gächter may be of interest.
Key sentence:
[W]e find strong evidence that many people’s attitude toward voluntary cooperation is conditional on other people’s cooperation… Moreover, the fact that many people contribute more the more others contribute also speaks against pure altruism explanations, because they predict that people reduce their own contributions when informed that others already contribute to the public good.
Basically, the paper argues (and justifies through a survey of experimental evidence) that a majority of people are ‘conditional cooperators’ who cooperate in community projects (voting, paying taxes, charity work, etc.) if and only if other people cooperate. If they think others are ‘defecting’ (i.e., not cooperating) then they will stop cooperating as well.
The paper also has some more detailed observations that come out of the experimental work; among them that voluntary cooperation is fragile; group composition matters (i.e., groups with more conditional cooperators will be healthier); and that ‘belief management’ maters- i.e., if people think that they are in a group with more conditional cooperators, that group will be more robust. None of these will come as a huge surprise to anyone who has been involved with volunteer communities, but still interesting to see it experimentally confirmed.
I’ve always suspected that something like this is the case, and that it explains in part why the GPL is so successful, since it uses copyright to force cooperation and penalize defection, and (importantly) makes a clear public statement that that is the case, which serves a signaling function (everyone in the community knows these are the ground rules) and a filtering function (people who aren’t interested in collaborating don’t join as much as they join other groups.)
The paper is only 25 pages and fairly readable; if you’re interested in the dynamics of volunteerism I recommend it.
Those of you who aren’t into economists and their fancy ‘measurements’ may also want to look at this related early paper, which is somewhat dated (the concept of low and high authoritarians is sort of discredited at this point) but still possibly of interest in explaining some of the psychological mechanisms at work here.
(Came to this by way of this paper on tax evasion, which looks to have many other interesting citations that I should investigate once exams are done. Only Telecoms left…)