KDE 4.1 RC1 here I come

It’s been a long time since I wrote my last blog entry. Truth is I’ve been quite busy first with final exams and then with different related tasks like having fun, burning myself in the beach, collaborating with PIRATA and yes, fixing some konqueror bugs, as we are in bug-fixing only mode.

So I’ve fixed all the known bugs for the two main features I’ve developed for konqueror, the undo closed items and the session manager and crash recovery dialog: KDE 4.1 RC1 is going to rock! Please report any bug you notice in konqueror and specially in the mentioned areas so we can have a KDE 4.1 release with no bugs in them. And of course…

This will be my first akademy, and I already know I will have a very good time there :-) and I will be able to see face to face nice people with which I’ve been in contact with for a long time already.

Nokia does not get it

Dr Ari Jaaksi is Nokia’s vice president of software and head of its open-source operations. Note that Nokia recently acquired Trolltech so now he has an important role in Qt’s future. An I’m worried because he has been quoted saying nonsense like this:

“We want to educate open-source developers. There are certain business rules [developers] need to obey, such as DRM, IPR [intellectual property rights], SIM locks and subsidised business models.”

No thanks you very much, but I don’t want software defective by design (not even the evils at Apple like DRM anymore), I don’t believe in imaginary property, and I hate SIM locks as much as the next guy.

“As an industry, we plan to use open-source technologies but we are not yet ready to play by the rules; but this needs to work the other way round too.”

You better start playing by the rules because else the other companies might do it faster than Nokia and you will lose the opportunity. Oh: And just as a remind: when you go open source, you *must* play by the rules by honoring the license of the software.

Really, it’s sad to listen to things like this from someone controlling the company who owns Trolltech  I am sure that the vice-president of companies like Red Hat wouldn’t say nonsense like the above. But it’s no surprise coming from someone in a company that seems to be absolutely in favor of software patents in Europe according to FFII.

Random updates

The final exams are coming soon and I should study, so I guess that’s why I’m here again trying hard to find something else to do… other than studying.

Tonight pinotree told me he found some memory leaks in konqueror and that I should try running valgrind against it. I haven never really used valgrind, but he has been very helpful with that. We found some minor not really important leaks.. and then this really nasty leak that should have never happened and I’m really  glad we found and fixed in rev815027.

Each tab in konqueror contains one or more konqviews. Normally it’s just one. For each view, we hold in a HistoryEntries the information about the pages you visited so you can go back&forward in the history. Each HistoryEntry contains quite a lot of useful information like: the url, the locationbarURL, the postData, the page cache, etc. And the bug was.. the KonqView destructor was not deleting its HistoryEntries, so that when you closed a tab, they were not really removed from memory. Quite nasty if you ask me! And really easy to fix thanksfully, once the problem has been found.

I’ve also been fixing some konqueror sessions bugs just after the beta 1, and I plan to fix some more for the next beta so be tunned! Oh and by the way, for those coming to akademy, Akademy 2008 registration is already opened and of course I’ve already registered myself. I will go to all the events, and I will pay for a bike so we can go to nearby places riding a bike. I love cycling =). And I’m in the group “KDE España” so that all spaniards can be grouped together.

Some guy called “Sami Liedes” gathered together a quite large (50!) list of bugs he had with KDE 4 beta 1 in kde-devel, and looking at konqueror bugs only, I had found at least 3 of them already, and one of those three was directly related to my code and had already been fixed. I will investigate the remaining ones =).

Enough blogging for today, I guess it’s time to go to bed now

Licencia GPL vs. aplicaciones web. AGPL

Esta nueva entrada en el blog proviene de un mensaje que he mandado a la lista de correo de Sugus. Lo publico en mi blog porque quiero tener una URL que pasar a la gente cuando quiera que conozcan el problema que tiene licenciar bajo GPL software en red, y cómo la licencia Affero GPL lo soluciona.

Hay cierto desconocimiento sobre los términos de la GPL en las aplicaciones web. Creo que es importante para aquellos interesados en el software libre conocer realmente las implicaciones de la licencia libre por excelencia, la GPL.

La GPL y todas las licencias libres han de cumplir las cuatro libertades del software: poder ejecutar el programa, acceder al código, modificarlo y redistribuirlo. Pero estas libertades sólo las tienen los usuarios del software.

Edulix 2010

Si yo soy un usuario de MS Windows y quiero ejecutar el sistema operativo Edulix 2010, puede que tenga que pagar para ello. Si yo como creador del software elijo un modelo de negocio en el que sólo los usuarios
legítimos, aquellos que tienen binarios de Edulix 2010, puedan acceder al código cuando me lo pidan por email, eso lo permite la GPL. Y si elijo también que tengan que pagar 35€ para que yo les ofrezca una copia de Edulix 2010, la GPL también lo permite. Libre != Gratis.

Claro que.. cualquiera podría pagar 35€ y luego redistribuir mi software de manera gratuita.

Google

Ahora pongamos como ejemplo el caso del código del buscador Google. Nadie que no sea de Google tiene acceso a él, e incluso dentro de la propia compañía casi seguro que guardan cierto control sobre su código para que no haya filtraciones.

Resulta que los únicos que tienen acceso a los binarios o código de las páginas web de Google son los propios empleados de Google, y por tanto, son los únicos “usuarios legítimos”, por llamarlo de alguna manera. De esa forma, si el código fuese GPL y sus usuarios decidieran no redistribuir el código a
nadie, seguiría siendo técnicamente software libre, igual que cuando te bajas un programa que sea software libre, lo modificas y no lo redistribuyes.  Sigues cumpliendo con los términos de la GPL.

Eso es lo chocante: pese a que millones de personas acceden a la página web de Google todos los días, su código podría estar bajo licencia GPL y sin embargo todos éstos millones de personas no tendrían derecho legítimo a acceder al código fuente. Desde mi punto de vista, es un fallo de la GPL.

Affero GPL (AGPL)

La licencia AGPL resuelve precisamente éste problema. Es una copia calcada de la GPL, pero añade una cláusula (sección 2(d)) que añade la obligación de distribuir el software si éste se ejecuta para ofrecer servicios a través de una red de ordenadores.

En el preámbulo de la propia licencia lo explican claramente (traduzco del inglés):

La Licencia Pública General GNU permite crear una versión modificada y dar acceso público a ella en un servidor sin tener que liberar el código fuente al público.

La Licencia Pública General de Affero GNU está diseñada específicamente para asegurarse de que, en esos casos, el código fuente modificado esté disponible a la comunidad.

Como véis no me estoy inventando nada. Eso lo dice la licencia oficial de la FSF. Ah por cierto también explican que la GPL v3 en principio iba a contener la famosa cláusula 2(d), es decir que iba a ser igual que la AGPL… pero que algunas empresas [1] no les gustaba la idea y por tanto la quitaron
de la versión final de la GPL v3. (y digo yo: vendidos!)

Lujury, conclusiones

Así que… Anarb, lo siento pero técnicamente Lujury podría perfectamente ser libre, GPL. Algunos me llamarán taliban por esto pero.. pero desde mi punto de vista la GPL y demás licencias que no tienen en cuenta el problema del software en red no son suficientemente libres. Stallman es un vendido, podría
haberlo arreglado en la GPLv3 y no quiso :-P. Tenemos la GPL en un altar y ésto nos puede llevar a confusión cuando no comprendemos realmente la licencia.

¿Mi sugerencia/solución? Para aplicaciones en red como las páginas web, licenciar el software bajo Affero GPL (AGPL). Y yo incluso abogaría por especificar éste problema para que las licencias que no lo resuelvan no sean consideradas completamente libres por la FSF o la OSI.

[1] Lo siento no he encontrado la referencia sobre lo de “algunas empresas”, pero juro que lo leí en alguna parte xD

Konqueror session management + crash handler

So as it was promised, konqueror session management is already done. I’ve just sent an email to kfm-devel with the patch attached and hopefully the patch will enter into trunk before the hard feature freeze (next monday) so that we get it in Konqueror 4.1.

The session management support is pretty similar to the one that Opera has. Let’s say it’s inspired in Opera =). And as everyone likes screenshots, here there is one that shows the new menus for session management:

So you can easily save current session, open one of the saved sessions, or manage current sessions. And only one more item was added to the File Menu, which is the same menu where session management resides in Opera.

The Manage sessions dialog lets you save current session in a new session or in an existing session (overwriting it). It also can rename an existing session, or delete it. Or even open one of those sessions. Quite straightforward if you look at it, actually:

And I have reserved the best part for the end. Proper crash session recovery! Because Konqueror shouldn’t, but it can crash sometimes. And it crashes even more when you use KDE trunk. Until now, the only option you had to recover from a crash was using the crash plugin which is sub-optimal.

What I’ve done is something similar to what Opera, Firefox and many others browsers do: Save session every X seconds (it’s configurable via konquerorrc, 10 seconds by default as in firefox). This is done for all konqueror processes, and it’s saved in ~/.kde/share/apps/konqueror/autosaved/. Each process saves its session timely there in a file with a name similar to “:1.114″ which identifies it. When a konqueror instance is closed cleanly, its file is removed.

Thus, every time a new window or konqueror process is launched, Konqueror reads that directory and asks to DBus if there’s any service registered with the name “:1.114″, for example, or whatever name have the autosaved files. This is done very fast, because no text parsing or waiting is needed, so the user doesn’t feel any delay.

If for some reason there’s a file with a name that is not related to a registered dbus service, that means that something wrong happened i.e. a konqueror process crashed or froze. And in that case, you get this nice dialog:

Which allows you to restore session if you want, or not, or even not restoring it now but restoring it later (opening a new konqueror process / window). As David Faure suggested me, it also allows you to check “do not ask again” and always do whatever you choose automatically without asking everytime. Nice isn’t it?

There’ still some related fixes I want to add to SVN before hard feature freeze, like adding a KAction menu to “Hibernate konqueror”, i.e. Save current session and close konqueror, so that next time you open konqueror it can be restored. Also listing the crashed and still not restored sessions (i.e. you clicked in “ask me later”) in the sessions menu.

Oh and adding an option to undo closed tab to right click menu of the konqueror tabbar is a must too, I use that option a lot now in firefox and we need it too ;-).

Tu otro banco, y cada vez el de más gente

Imagen de un sintecho

Gracias a Fernando por pasarme ésta genial fotografía.

New kid on the block (Part II)

Knock knock?

kDebug() << “Hello Planet KDE!” << endl;

If everything has gone right, I’m already in the show and prepared to rock this feed with my new shinny blog. I figured out that I should participate more in the community, talking about what I do in Konqueror, and perhaps I can even attract more new developers to Konqi or current konqueror developers to Planet KDE. Either of those ideas seems nice to me.

I didn’t get in GSoC but that doesn’t mean that I won’t continue working in KDE/Konqueror, quite the contrary, it only means that I will continue doing just for fun only =). In a following post I will talk about the incoming session management support for Konqueror, which hopefully will end up in KDE 4.1.

New blog on the block

Hello everyone! Here is my new shinny blog. A veces escribiré en español, and some other times I’ll write in English, mostly when I want to appear in KDE planet. I will talk about my works on Konqueror, the Google Summer of Code in case I get accepted, and who knows what more. We’ll see.