my blog

GNOME

Entries feed

Tuesday 13 April 2010

GSettings Hackfest: Day 1

Yesterday was the first day of the GSettings Hackfest! Ryan, Matthias, Colin, David and I were locked in a meeting room for the whole day (okay, we went out for lunch and Matthias had to leave afterwards) and we put our brains to good use. Or at least, that's the feeling I got ;-) But first, let me thank the various companies who are helping this hackfest: Novell is sponsoring and hosting it, and Red Hat and Codethink are sending folks here. This hackfest will most certainly make a difference on our road to GNOME 3.0, and the support of those companies is a great contribution! And obviously, without the Foundation support, the event wouldn't have been possible, so here's lots of love from the participants to the Foundation too :-)

We spent the morning planning and discussing various topics, and the afternoon was more like a coding session. Unfortunately, we didn't take any fancy picture, but we'll try to do a better job now. Matthias put some notes online, and here's my attempt to summarize the day (with probably a few errors here and there...).

Emma's Pizza

Emma's Pizza by afagen (Creative Commons by-nc-sa)

Overview

Ryan gave a general overview of GVariant/GSettings/dconf. Here's a quick summary:

  • GVariant is the part that landed in glib 2.24 (released at the same time as GNOME 2.30). It's a datatype for values of a type that you specify, and which can be simple, or relatively complex (something with a mix of arrays, tuples, dictionaries, strings and integers, for example).
  • GSettings is an API to access settings. This is the main focus in this hackfest.
  • dconf is what will store the settings on the disk, and it's a backend for GSettings. So it's actually only an implementation detail; there's also a simple memory-based backend that makes it easy to test GSettings without dconf.
  • There's also a GObject serializer that exists in a branch, but it needs to be reviewed and it's not something that is blocking anything major.

So what's important in there for developers? The GSettings API is what you should care about, and it's relatively straight-forward:

/* Get settings associated with the org.gnome.hello schema. We now specify
 * directly which schema we want, instead of just a path like in gconf. */
settings = g_settings_new ("org.gnome.hello");
/* Fetch a tuple of integer that are stored together (instead of using two
 * distinct keys, like in gconf). */ 
g_settings_get (settings, "preferred_size", "(ii)", &width, &height);
/* Set a string-typed key. */
g_settings_set (settings, "username", "s", "Rupert");
/* Bind a setting to an object property. */
g_settings_bind (settings, "show_picture", image, "visible", G_SETTINGS_BIND_DEFAULT);

There are already two modules with a gsettings branches: devhelp and gedit. While they probably won't work straight away with the final GSettings, it certainly helps get a better view of what porting involves. Unfortunately, a few things need to be completed before GSettings is usable again, which makes it not really fun to do some port right now. But things should be better really soon now.

For distributors and sysadmins, knowing a bit about dconf will still be important since this is where the settings will be stored, and this is the part the will be used to implement non-schemas default values or mandatory values.

Timeline

We obviously discussed planning, and one explicit goal that was set is to merge GSettings in glib at the end of the week. We'll see how it goes, but that's definitely doable since it's not that big.

There's the question of whether all of GNOME can be ported to GSettings in time for GNOME 3. I do hope it will happen, but we'll certainly know more at the end of the week once we've started porting applications using gconf in interesting ways.

Schemas

While there's already support for schemas, it's not set in stone yet and it can be improved in various ways. Among the things we discussed:

  • The current format is a really simple format that is easy to write and parse for human eyes, but it's not flexible enough to do everything we need. So we worked on a complete XML format, which is still relatively intuitive. However, we expect to make it possible for developers to use the simple format and compile it to a XML file with a small utility during the build.
  • The schemas are compiled in a database, that will only contain the default values and potential constraints about the values for a key. So if an application wants to access the description of a key (which is the exception, not the usual case), it will have to parse the XML files for this.
  • Translations of the descriptions will be fetched with gettext, since they will already be in the .mo files and there's no need to duplicate this information.
  • How to handle localized default values. This is useful for various settings (clock format, default search engine, etc.), so it's definitely something we want to have. Application developers will have to explicitly mark a key as localizable. We're still debating whether all types of settings should be localizable, or if it's only strings. So don't hesitate to share with us good concrete example of non-string settings that should have a localized default value!

While there are still open questions, we made good progress on this, which will enable us to move to other topics quickly.

Configuration Migration

Migration of configuration is a tough topic, and we're unsure what's the best approach here. We quickly brainstormed about some possibilities:

  • An easy solution would be to just do nothing. It might look brutal at first, but the gconf schemas that are defined by applications today are often suboptimal in various ways, and maintainers wouldn't be unhappy to be able to change a few things here and there. Also moving to GNOME 3 can be seen as an opportunity to do a clean break. But we already know that this would be annoying for users.
  • The other extreme solution is to migrate all the gconf database at once. The issue with this, though, is that it assumes that applications stop using gconf at the same time, which is not going to happen: we don't have control over all the applications that are used by users. So a user might change the settings of an gconf-based application after the migration has been done, and those changes will never get migrated, even if the applications gets ported later.
  • An approach where it's up to each application to signal when to migrate its data (and maybe even which part of the data to migrate, with a file mapping gconf keys to GSettings keys) is a third alternative. It looks relatively attractive, but it also has a simple issue: what happens to the shared settings, like everything living under /desktop/gnome?

So no obvious magic solution (surprise!), and we clearly need to think more about it this week.

Best Practices

It's a topic that came up more than once. We certainly need to define some best practices on how to write schemas (how to name keys, what should be in the description, etc.) and as to when to use GSettings. For the schemas best practices, we can certainly look at what is recommended for gconf, although there are requests to change a few things (prefer dash to underscore, for example).

When to use GSettings is a fun topic: it's really something that should be used to store settings, and not state. So the position of a window, for example, would not be appropriate to store in GSettings. However, without a good API to store transient data, it's likely that GSettings will get abused for this like gconf is being abused. And it seems we don't all agree on what is a setting and what is transient data: having an expander open is an interesting case where Ryan and I are happy to disagree :-)

D-Bus discussion

Hrm, okay, I didn't listen too much to that part of the discussion, so I have nothing really interesting to write about it. But with Colin (who doesn't admit yet he maintains D-Bus) and David (who's writing gdbus) together, there was probably insightful opinions :-) The good news is that gdbus should be ready soon, and I heard some talks about porting gvfs to it...

Hacking

So as you can see, there were a good number of topics discussed. But we slowly turned to our editors after lunch: David focused on gdbus; Ryan worked on GHashFile, an API to store data on disk, which will be used by dconf; Colin progressed on GtkApplication; I did some stupid work to save GSettings stored in the memory backend to keyfiles.

So what happens today? We'll see when the hackfest begins, but it looks like we'll be able to use GSettings again, at least with the memory backend, which will make it easier to review the GSettings branch and start porting applications.

Wednesday 31 March 2010

Enjoy GNOME 2.30!

GNOME 2.30

Amazing banner for Two Thirty by Andreas Nilsson

It's out and it's good :-) Go read the release notes to get more details about 2.30! You know the drill now: this release is already included in the development branch of most distributions, and you'll see it in stable distributions released in the next few months.

I've thought hard about it and after careful consideration, I'm positive that my favorite change in this release is the redesigned Swell Foop (previously named Same Gnome). Sure, it's neither the most visible change nor the most useful one, but the new clutter-based engine for this simple game makes it really addictive!

If you use openSUSE Factory, GNOME 2.30 is already available from the GNOME:Factory project in the build service, and I pushed it to Factory today, so it'll be in the next milestone. But there's more! I really love the fact that we're able to easily ship the latest releases of various applications for our stable openSUSE release. Yes, that means that if you're an adventurous openSUSE 11.2 user, you can also play with it today! There are instructions for 11.2 users on the wiki, but please do read the warning at the top of the page :-) The GNOME team will work a bit on it to make sure it's all stable so that non-adventurous users can also enjoy it!

Many thanks to everyone involved in this release, especially to the various people who helped for this release in the last few days — there were more late tarballs than usual, for example, but we still managed to get 128 new tarballs compared to 2.29.92 (and I ended up rolling 30 tarballs myself, a new world record!). And my good friend Andreas saved my world again with his 2.30 banner :-)

Now let's have an ice cream party!

Tuesday 9 March 2010

Help GNOME be present at Idlelo, in Ghana!

A few weeks ago, the GNOME Foundation has been contacted by the organizers of the Idlelo conference in order to get a GNOME presence during the event. Quoting the website of the event:

IDLELO is one event for FOSS practitioners, developers and advocates as well as governments to showcase results, share experiences and challenges, review progress on the continent in diverse domains and chart a way forward for an African future grounded in true ownership of technology. IDLELO is therefore a premier international forum for the presentation of research results in Free and Open Source Software (FOSS) in Africa.

The event will occur in May, in Accra, Ghana.

There have been many discussions in the past about how to get more community involvement in Africa, and there's no magical solution. But a good first step is, for sure, to be present at events that are being organized on the african continent. We're already sending Luis de Bethencourt to FOSS Nigeria, and we want to be at Idlelo too.

If everything goes well, the amazing Fernando will go deliver training sessions before the conference itself; but we need one more person to man a booth during the conference. While this is not a hard requirement, we'd still like to have a GNOME Foundation member who feels empowered to talk in the name of the Foundation. If you're interested in representing GNOME at Idlelo, please get in touch with the board. I'm sure you'll enjoy it!

Monday 8 March 2010

Tidbits from the Usability Hackfest

If you're still wondering what happened during the Usability hackfest, then you clearly missed a lot of blog posts. The good news is that you can catch up with all the links being collected on the Hackfests, or you can cheat and go read Máirín's coverage, since she did an amazing job writing about what was being discussed.

I was there only for the last two days; the original plan was to attend a bit more of the event, but the travel from France to London took an unexpected 12 hours. I still had some good and useful time there, that I mostly used to get a good overview of what people are working on, and how this can be integrated in a GNOME roadmap. Here are some highlights:

  • While I missed the discussion about nautilus, it seemed most people at the hackfest agreed on streamlining the nautilus user interface. I'd love to try the prototypes that were worked on: most of the proposed changes make sense to me. But getting rid of tabs and/or the split view will certainly trigger various reactions, and that's something that we cannot ignore...
  • Thomas je parle français couramment Wood was kind enough to let me use his laptop charger nearly all the time — I had one, but not for the right laptop...
  • Charline reported about a usability review of empathy, and this was definitely instructive. It's always fun to look at a user interface and finds what's wrong and what can be improved. In some way, it reminded me of some usability reviews that the usability team was doing for various applications a few years ago. That's an effort that we've been missing lately, and I'd love to see someone revive this!
  • The work on the new control center seems to be moving along nicely. We should see the results in the next development cycle; don't be afraid to help Thomas if you're interested in this!
  • While discussing preferences, and removing some of them that we think most (as in a huge percentage) people don't use, we mentioned the fact that when we remove some settings from the various configuration tools, a lot of people get unhappy, to say the least. This is understandable, but we also always pointed out that it should be easy to write a small tool to enable people to change those settings graphically again. That never happened, but we'd like to avoid further unhappiness. This is how the idea of GNOME Plumbing was born. And I foolishly proposed to implement this.
  • It was funny to see Garrett breaking his openSUSE installation. Except that it shouldn't break this way when using GNOME:Factory on 11.2. Oops.
  • I had a good chat with Jon about GNOME 3. There's so much we can deliver during the whole GNOME 3.x cycle... We're focusing on 3.0 right now, but we need to prepare the following releases too. It was motivating to get reminded of the various areas we should explore, and motivation is something that was most welcome :-)
  • It was good to catch up with Lucas, just a few days before Julia magically appeared :-) He's still one of my heroes.
  • On Friday morning, Bastien told to Mairin, Garrett, Jakub and Hylke: okay, you want tools for designers; we're a bunch of hackers here, but we need you to design the tools you need. This resulted in a good discussion. Except that now, we really need some people to sit down and implement this. I guess this could be an interesting Summer of Code project!
  • Seeing Willie get hopes for usable accessibility support in GNOME Shell was a real pleasure. It's been a hard topic for months, and knowing that there might be some light at the end of the tunnel is already good news.
  • Matthew invited me to a card sorting session about settings and how to group them. It was a new experience for me, and seeing someone struggle to organize settings was eye-opening: I got the feeling that even with just one person doing this seriously, we can improve the overall experience for many users. I'm intrigued how usability people deal with different people having conflicting behaviors, though.

Many thanks to Canonical and Google for sponsoring this hackfest, and also thanks to Klaas and Novell for letting me go on a short notice :-)

I have high hopes that putting all those designers and usability people in one room together during one week will also make the GNOME Usability team move forward again. Usability is an essential part of our DNA, but we've been slowing down our efforts there, instead of accelerating as we should have done. This hackfest should put us back on track!

Wednesday 24 February 2010

London, here I come!

I'm going to the Usability Hackfest in London today! Seeing the pictures on Máirín's post (more pictures) makes me feel it's already going quite well, and I'm eager to sit down and listen to clever people.

I'm saying I'm going, but I should probably say that I'm supposed to go: there's a strike in french airports and yesterday, I learnt that the airport where I'll take the flight to London is supposed to be closed. At least the flight wasn't cancelled. Yet. Oh well, I guess we'll see how it goes ;-)

Update: of course it happened. Flight got cancelled while I was on my way to the airport. After some challenging times (they had no computer working because of bugs), I'm now at another airport, waiting for a flight in the afternoon. But I'll make it :-)

- page 7 of 36 -

by Vincent