Recent blog entries for zeenix

GUADEC

So its that time of the year! GUADEC is always loads of fun and meeting all those the awesome GNOME contributors in person and listening to their exciting stories and ideas gives me a renewed sense of motivation.

I have two regular talks this year:
  • Boxes: All packed & ready to go?
  • Geo-aware OS: Are we there yet?
Apart from that I also intend to present a lightning talk titled "Examples to follow". This talk will present stories of few of our awesome GNOME contributors and what we all can learn from them.


Syndicated 2014-07-21 23:12:00 (Updated 2014-07-21 23:12:07) from zeenix

oFono? Its dead jim!

Soon after I mentioned the need for an oFono-backend in Geoclue in my blog, Sri kindly helped me get in touch with oFono developers. What started as a nice friendly discussion soon was turned into a not so nice discussion. I won't get into details and blames but here is what I found out about the project:

  •  oFono developers claim that its is still a maintained project while rest of the world think its a dead project, even people who love the project. Last release being in 2012 and loads of missing essential features (see rest of the points below) and link to mailing-list broken (even though I pointed it out 3 weeks ago and its been broken for much longer) on the homepage all points to the fact that its essentially a dead project.

  • No proper D-Bus introspection nor any client libraries. This already makes it extremely difficult to work with oFono but wait there is more hurdles on the way.

  • No online cross-references documentation: The documentation link on the home-page leads you to an architecture diagram and gives you no information about the API. Searching through google doesn't yield any results either. The developers pointed out that all documentation lives in the source tree in the form of plain-text documents and hence not very appropriate for the web.

  • It does not implement the standard D-Bus Properties interface. This combined with the fact that their D-Bus API is heavily based on properties makes it yet even harder to work with OFono, not to mention very weird.

  • None of the modern 3G modems supported, at least out of the box. I tried both Option and Qualcomm Gobi that I have and they both didn't work.


While rest of the issues can be overcome, the last makes it impossible for me to test any code written against oFono. So I'm giving up on this.

With a nice alternative that is well-maintained, and with which most modems work out of the box, has a nice OO, well-documented and introspectable D-Bus API and also provides  a nice client library, I don't understand why phone vendors insist on supporting oFono interface. Could it be because the name makes it sound like its *the* solution for phones? Well, they do have the right to use whatever they like. I'm just curious.

Having said all that, I did make it easy for anyone to add oFono support to Geoclue as promised in my last blog post. Patches to add that are more than welcome!

Syndicated 2014-06-24 00:28:00 (Updated 2014-06-24 00:28:43) from zeenix

Location hackfest 2014 report

So the Location hackfest 2014 took place at the awesome Mozilla offices in London during last weekend. Even though some of the important participants didn't manage to be physically present, enough people did:
  • John Layt (KDE)
  • Hanno Schlichting (Mozilla)
  • Mattias Bengtsson (GNOME)
  • Jonas Danielsson (GNOME)
and some participated remotely:
  • Bastien Nocera (GNOME)
  • Garvan Keeley (Mozilla)
Unfortunately Aaron McCarthy of Jolla couldn't attend remotely either as he lives in a very incompatible timezone (AU) but we had a lot of productive discussion with him through email that still continues.

Some very fruitful discussions we had:

  • Why Mozilla doesn't make wifi data it gathers for its location service, available for everyone to download? Hanno explained in great detail how making this data available would seriously compromise privacy and even safety of people. One good example given was someone getting out of an abusive relationship and not wanting to be traceable by their ex- but if they take their wifi router with them, their significant other has a possible way to easily track them using the wifi database. There is an easy (even though very ugly) way to avoid your AP being scanned by harvesters of such services but most people do not possess enough technical knowledge to know to enable that.

    Hence their reluctance to making it available for download, even though they'd want to. If you are interested in more details, you should read up all about that on Hanno's blog.
  • Had some discussion with Firefox and Firefox OS using Geoclue2. Hopefully we'll at least have Firefox using Geoclue2 soon. I might need to add support for totally unmaintained ofono in Geoclue2 unfortunately for making a very compelling case for Firefox OS to adapt geoclue2.
  • We had a discussion about GPS-A support in Geoclue. There are two possible ways to do that:
    1. Give URL of a SUPL service to the modem and let it do everything for you.
    2. Get the geospacial data that (SUPL service would provide) from a custom service and feed that to the modem.
    Hanno informed us that the only free SUPL implementation out there is that from Google but nobody knows what the ToS really are. He also informed us of how many modem chipsets just don't implement the API to feed it geospatial data and that makes SUPL our only hope to implement GPS-A.
  • There was a discussion about POI and check-in UI in Maps between me and Mattias. We had a bit of disagreement about it but seems now we are coming to come conclusions about how it should look like.
It was a hackfest so we also did some hacking:

  • John spent most of his time getting familiar with Qt's location code and how to port to Geoclue2. He wrote a nice post about it so I wont get into details here.
  • Mattias worked tirelessly to finish off his routing branch to be finally merged. Its not a very easy task so its not surprising that he hasn't managed to finish it yet. I'm pretty hopeful it will be merged in the following few weeks.
  • Hanno added proper support for geoip-only queries in Mozilla location service, made it do better against queries w/ stale wifi data and improved accuracy of results from 300m to 100m among other things.
  • Jonas was doing live reviews of Mattias' patches (in Swedish!) and at the same time working on getting command-line options parsing to work in gjs so we can do so in Maps.
  • Garvan was working on adding Geoclue2 support to Firefox/Gecko.
  • I finished off my patches to port geoclue2 to directly use wpa_supplicant rather than NetworManager, which makes wifi-geolocation work on FreeBSD, Firefox OS and Jolla. The last two don't use Geoclue2 but I'm hoping that this is a step forward towards convincing them to use it. I provided a patch to wpa_supplicant to make its D-Bus policy a bit lenient, while at it.

    I also looked into ofono API but not only is the project unmaintained, it doesn't provide proper introspection on D-Bus and there is no API docs. :( To make things worse, both my modems don't seem to work at least out of the box. I'd really rather I didn't have to deal with it but if I can't convince Firefox OS folks to provide ModemManager API, adding ofono support is essential to get them to use Geoclue.

    I started refactoring of Modem sources in Geoclue so that:
    • all ModemManager code is isolated in its own module so that its easy to add a ofono handling code w/o changing anything in the sources themselves.
    • 3G source can more easily/cleanly share code with Wifi source, use Mozilla Location Service (rather than opencellid that it currently does) and also submit cell tower data to Mozilla.
I can't thank Mozilla and specifically Chris Lord enough for hosting this event for hosting this event.

    Syndicated 2014-05-28 11:57:00 (Updated 2014-05-28 11:58:39) from zeenix

    Berlin, DX hackfest, Boxes, rain & sunshine

    I just flew back from Berlin where I spent the last week, mainly to participate in the GNOME Developer Experience hackfest. As you can see from blog posts from other awesome gnomies, the hackfest was a pretty big success.

    I focused on the use of virtual machines (as thats right up my alley) for making application development as easy as possible. I talked to Christian, who has been working on an IDE for GNOME about his idea of a simulator VM which allows the developer to quickly test their app in a pristine environment. We discussed if and how Boxes can be involved. After some discussion we decided that we probably don't want to use Boxes but rather create another binary that re-uses the existing virtualization infrastructure: libvirt, qemu, spice (and maybe libosinfo) etc.

    Another way to make GNOME development easy through VM would be what we already have on a very crude level: Distribution of ready-made VMs with all the development environment setup. Continuous already creates and distributes ready VM disk images of latest GNOME (almost everything from git) and Boxes can import these images. These images however are insufficient and unreliable since they do not contain any metadata, especially recommended/required system resources, about the VM. Christian recommended VMware's wmx format but that turned out to only contain metadata instead and you'd need a separate file (vmdk) for the disk image with that. What we really need here is a format that contains both metadata and all disk images in one file, in other words a virtual appliance. After doing some research on this, I once again came to the conclusion that OVF is our only hope here. Not only its one file that can contain all important aspects of a VM, its an open standard that is agreed and implemented by many different vendors. Boxes being able to import/export from/to this format and Continuous being able to provide these virtual appliances wouldn't just enable a more reliable producer-consumer relationship between Continuous and Boxes but also allow individual developers to be easily able to share their work with others: "Hey! I've been working on this project/feature X last few days and want to get some input. I'm sending you the VM, just import it in Boxes and let me know what you think..".

    We've actually been wanting to have this feature for a very long time and I've mentioned the need for OVF support quite a few times so I decided its about time I do something about it. So during the hackfest, I designed the minimum interface for a library to convert from/to libvirt domain (or configuration) to/from OVF files and started the implementation too. I hope to continue working on it to have something demoable by end of this month.

    Some other discussions/activities I had during/around the hackfest:

    * Talked with Aleksander about modem enabling/disabling. Currently geoclue has to enable the modem itself for using it but since it doesn't know if the modem is in use by another application, it doesn't disable it after using it. This results in waste of battery power. I suggested to Aleksander that the best thing would be for ModemManager to take care of that as it knows if modem is in use or not. The alternative would be some kind of explicit UI but throwing this decision on user would be a terrible thing to do. Aleksander liked the idea and he promised to look into implementing it.

    * I took part in Gtk+ roadmap discussion, mostly as a silent observer (Gtk+ hackers and designers covered it nicely so I didn't feel like saying anything) but during the meeting I learnt of a widget that was introduced in 3.12 that I had missed completely, GtkFlowBox. Since developers were unhappy that we introduced a widget that is not used by any GNOME app and I realized that use of this widget in Boxes will bring me very close to my aim of dropping libgd usage, I decided to make Boxes the first user of this widget soon.

    * I realized (very late) that both my SoC studends live in Germany so I asked both of them if they can join us for any of the days. While it was impossible for baedert to join us on such short notice, Lasse was still able to make it for the last day. It was really nice to meet this very bright young fellow. We had a lot of discussion about past, present and future of Boxes. Lasse has already written a very nice and detailed blog post about that so I'll leave you with a link to that if you are interested.

    * Talked with Cosimo about use of Geoclue by Endless mobile.

    * Tested gnome-clang against Geoclue to provide feedback to Philip and it resulted in him fixing some important bugs.

    * Talked briefly to Lennart about
      * How authorization of geoclue-using apps will/can work in the kdbus world.
      * The best way to allow Boxes to access USB devices with ISO9660 filesystems on them.

    Thats mostly it! I would like to thank Lennart for providing me with a nice accommodation, Endocode for providing us a great venue (+ endless supply of Club mate) and GNOME foundation for sponsoring my travel.




    Syndicated 2014-05-05 23:41:00 (Updated 2014-05-05 23:42:32) from zeenix

    What's coming in Maps 3.14 and beyond

    Jonas has written a very nice blog post about present and future of Maps project. I definitely recommending reading it if you are interested in this project. Since he is not on planet.gnome yet (some policy about having some posts before applying to be added), I thought I share it here.

    Syndicated 2014-04-22 11:30:00 (Updated 2014-04-22 11:30:31) from zeenix

    13 Apr 2014 (updated 13 Apr 2014 at 19:08 UTC) »

    Location hackfest

    I'm organising a hackfest in London from May 23 to 25 2014. The plan is to improve our location-related components and to get them useful to other OSs: KDE, Jolla and hopefully also Ubuntu phone. If you are (or want to) doing anything related to location and want to attend, please do add yourself to wikipage as soon as possible so I can notify our hosts if we'd need a bigger room.

    Oh and if you need a place to stay, do contact me!

    I'm thankful to awesome Mozilla folks for hosting this event and providing an awesome open geolocation service to everyone.



    Boxes 3.12

    I just rolled out Boxes 3.11.92, which is going to become 3.12 in a week. Apart from lots of fixes and minor improvements like addition of keyboard shortcuts for improved accessibility for example, there are some note worthy changes against 3.10:
    • Dropped use of clutter and clutter-gtk: While it was a good idea to mix gtk+ and clutter at the beginning of the project to make most of the animations and transparency controls possible, Gtk+ gained new API over last few years to make most of what Boxes needed, possible. So I decided to attempt to remove clutter* from the picture and I'm glad to report that my attempt was a success. This means:

      • Less animations: Some of the animations we had are still not possible with Gtk+ (at least not in any easy/nice way) so they had to be dropped but they are nothing really essential to how Boxes work and were only good for impressing first time users. I'm talking about box thumbnail flying around the window for transitions between different UI states.

      • More animations: Making use of new Gtk+ API, we gained some nice animations for UI transitions that nicely makes up for the dropped animations. Here is a video of Boxes 3.12, where you can see all these animations.



      • Simplified code: Removal of clutter actors from widget hierarchy also made it easier to simplify the hierarchy quite a bit. I also took the liberty of moving most of the UI setup to UI description files separate from rest of the code. So overall the code is a lot cleaner and therefore much easier to maintain, hence removed clutter even literally.

    • Ability to easily import existing VMs from system libvirt: Many people have been using virt-manager for years and while they'd want to use Boxes, them not being able to easily use their existing VMs wasn't  encouraging them to switch. Now we've fixed that.



    • NAT networking: Since the very beginning of the project, one complain we kept getting was that the default network setup by Boxes in VMs was slow and VM was unreachable even from the host machine. This has finally been fixed by Boxes now setting up a NAT network in new VMs using the special bridge network setup by libvirt. This means that all VMs are on the same private (to host) network and therefore VMs and host can directly communicate with each other. Its also much faster than 'user-mode' networking we've been using till now.
    Thats basically it for this release! Now some features I'd want to add in 3.14:

    • Import and export of VMs. Doing this properly will involve creation of a new library that deals with OVF. I'd like it in a library because there is at least one project (apart from Boxes) that can make use of it: gnome-continuous. Boxes already allow you to import the qcow2 images gnome-continuous produces but since this image does not provide information about the VM itself, you can very easily find yourself creating a broken VM with them. QXL breaking every other release and gnome-continuous tracking git master of that does not help at all here /rant. So if continuous would provide OVF files instead of raw disk images, it can tell Boxes to use 'vga' rather than 'qxl' whenever QXL is known to be broken.

    • Support for express installation for many other OSs/distros, especially Debian/Ubuntu. The idea has been proposed for SoC and there is already one student that has applied for it.

    • Support multiple monitors in VMs.

    • Snapshots: You went for an OS update and it completely destroyed your VM, what do you do? Snapshots will make it possible to save the VM for you before you go for that OS update so that if things go south, you have a way to easily recover. What if you installed multiple updates at different times and you don't know which update caused the problem. Snapshots will also make it possible to save multiple checkpoints of your VM so you can go back to any of them and then use the one that was not broken. Pretty cool if you think about it and makes you wish you could do the same with life. :)

      This idea has also been proposed for SoC and there are two students who have already applied for it.

    • Downloading of ISOs and images (and also VMs, after we have the VM import feature in place). Currently you can't give Boxes URL of a remote ISO or image and expect to be able to handle that. We need to fix that but automatically downloading the ISO/image for you. To make it even better, would be nice to:

      • Autocomplete URLs while you type it in the wizard using the list of known URLs in libosinfo database. E.g you type "Fed" and URLs of all Fedora releases get proposed to you, you keep typing till "Fedora 19", you already have a URL to hit enter on.

      • Provide a way to add entries to the ready menu you get in the wizard. This will allow us to provide 'a few clicks' ™ way for user to try latest GNOME unstable releases and distros to do something similar for bleeding-edge/development snapshots of their distro.

      This has also been proposed as second part of the "Automated installation" SoC project I mentioned above.

    Syndicated 2014-03-19 15:11:00 (Updated 2014-03-19 15:20:41) from zeenix

    Geoclue 2.1.1

    I just rolled out Geoclue 2.1.1! Since my last post with Geoclue update, there has been lots of changes. You can find a list of all the changes here but here are the highlights:

    • Modem geolocation: If you got a 3GPP modem, geoclue will now be able to use that to locate you (with neighborhood-level accuracy) using opencellid.org. Additionally if your modem has GPS capability, geoclue can use that as well and as you know GPS is the most reliable geolocation source.

      One issue with GPS currently is that it takes a while before it can get a lock on and reason for that is that we currently have no support for A-GPS. I'll be talking with Aleksander Morgado during the weekend about how we can add that support but if I've understood correctly, it will need more work in ModemManager than geoclue now that it has all these other sources.

      Geoclue locating me using 3GPP source

    • WiFi geolocation: In my last relevant blog post, I mentioned that we'll be implementing this using Open WLAN Map project but around the same time Mozilla announced their own public geolocation API. After careful consideration, I decided to go for Mozilla Location Service. So geoclue now has a geolocation source that makes use of this public service.

      This service being very new, doesn't have a lot of data. If you want to help us (GNOME), Mozilla and all users of this service and geoclue, you can gather data using MozStumbler android application, which should work on most (if not all) android phones. I also implemented data gather in geoclue but it requires a GPS-enabled 3GPP modem and (at least for now) needs to be explicitly enabled in our configuration file.

      An advantage of using Mozilla Location Service is that it offers a Google geolocation compatible API as well. Geoclue uses this compatibility API and you can make it use Google's geolocation service instead by tweaking an option in our configuration file. Please note that geoclue is not responsible for any misuse of Google API. Please do read their ToS before use and you'll need to get yourself a key before you can use their API.

    • API to check if geolocation service is in use and next version of GNOME Shell will make use of it to show an icon in the panel to indicate to user that their location is being accessed.
    GNOME Shell indicator for 'location services in use'

    So keeping all this in mind, I'm pretty happy with our progress on geoclue2. I will be in Brussels this weekend. Unfortunately my submission about geo* to desktop devroom didn't make it to the shortlist (which I hear is half as short as last year's) but feel free to talk to me about geolocation and maps etc if you are around.

    http://fosdem.org/

    Syndicated 2014-01-30 15:52:00 (Updated 2014-01-30 15:52:50) from zeenix

    Moving to London, UK

    For those who haven't heard the news yet, I'll be joining Red Hat UK and terminating my Red Hat Ltd, Finland branch contract starting Nov 1 2013. Naturally, I'll be myself moving to London soon along with my wife and cat.

    I'm about to embark on a trip to Canada and US to attend Boston Montreal  and Google Summer of Code mentor summits and I'll return on Oct 22. Two days after that I fly to London to start the hunt for a decent apartment. Once I have an apartment, my wife and cat will come over as well.

    That's all folks.

    Syndicated 2013-10-05 03:00:00 (Updated 2013-10-05 03:00:06) from zeenix

    GNOME 3.10, 3.12 and me

    Wow! Its been months since I last blogged. I have a good excuse and a bad one. The good one is that I've been extremely busy with trying to get some of things ready for GNOME 3.10. The bad one is that w/ me sharing all important events on all 3 major social networks, I don't feel too motivated to put all those into blog posts (yes, I'm very lazy).

    As you probably already know, I've been working on Maps, geolocation and geocoding apart from Boxes in 3.9 development cycle. Although there is still a lot of work to do in all these, I'm really happy with what we achieved in a short amount of time:
    • Maps: There was  desire and design page for a map application for GNOME but I didn't see any implementation. I looked around and found out that Mattias Bengtsson had already a repository so I helped him start the project. Currently it only allows you to some basic things you expect from a map application, like searching for places and finding your location but for a preview application that was developed in a few months by a few people, its a big achievement that everyone involved should be proud of. We still have plenty to do for 3.12, where its supposed to be a useful and stable application and not just a preview. Unfortunately, I myself won't have a lot of time for Maps in this cycle, so if you are interested in maps (lots of fun guaranteed!) and are looking for a way to contribute to GNOME (or Free Software in general), here is your chance to change the world for better.



      Since Maps use the awesome OpenStreetMap project (through libchamplain), another way to contribute is to edit maps directly in OpenStreetMap itself. This is ideal for technology enthusiasts who lack programming skills or interest in it. That is not to say that almost everyone would enjoy this kind of contribution. My good friend, Federico tells me that it could easily become an addiction. OpenStreetMap has several editor clients for different platforms so you can choose the one that suits your needs.

    • Geoclue2: So we basically started a re-write of Geoclue some months back. Rationale could be found here. Currently we only have IP-based geolocation and that unfortunately is limited to city-level accuracy at best. While this is not enough for some applications (e.g Maps) its already serves well for some important applications like Clocks and gnome-settings-daemon. So in GNOME 3.10, your local clock is automatically added to Clocks and your system timezone automatically updated (if you choose so) as you travel around with your laptop.

      In 3.12, I would like to first address the privacy concerns: Users should be given control over which applications should be allowed to access their location. This will be done through per-user agents running in desktop sessions. I already have implemented the geoclue side of this and have implemented a demo agent but I gotta implement an agent in at least GNOME Shell before Geoclue by default requires all apps to be authorized. KDE (every linux-based OS) folks will also have to implement an agent if they intend to use Geoclue2.

      Once privacy in place, I would really want to add more geolocation sources: GPS, 3G and WiFi-based geolocation. The first two, I'm told should be easy to add w/ latest ModemManager.

      WiFi-based geolocation will most likely be based on Open WLAN Map project. I have not yet looked at the API their library provides but I'm hoping its not too hard. Implementation difficulty aside, one big issue is that their database is hardly comparable to that of Google, Nokia, Microsoft etc so in most cases (unless you are in Germany) we'll not be able to rely on this source to locate you. That is a pity since this is the only option we have for wifi-geolocation, being open database of this type. On the bright side, they provide easy ways to improve their database using your smartphone. I'm hoping that by making use of this service, we'll further encourage contributions to this database and in a few years, this database will have enough data from many different areas around the globe.

    • Geocode-glib:  As I said, Maps already allow you to search for different places on the planet. This is done through a process called geocoding. This process translates a string, which could be the place name or part of it, and gives you details about all places that match such a string. The most important part of these details are coordinates. Another small feature you might notice in Maps is the "What's here" item of the context menu, which shows you details about the place where you cursor currently is on the map. This is done through a process called reverse-geocoding. Simply put, given the coordinates of a place, you get details (especially name) about it.

      Bastien had been working already on a library for geocoding and reverse-geocoding called geocode-glib. Since I needed this for Maps, I helped clean it up. While doing so I realized that it used Yahoo Places service, which not only is a closed/proprietary service, it doesn't have enough data and most importantly is not designed to be used for geocoding. Turned out that OpenStreetMap folks provide an open service for geocoding, Nominatim I ported geocode-glib to use Nominatim instead of Yahoo Places. Since Nominatim shares the same database with OpenStreetMap, contributing to Nominatim is the same as contributing to OpenStreetMap and vice versa and you use the same clients/tools to do that.

    All this would not have been possible without help from our awesome community. Special thanks goes to my Google Summer of Code students, Kalev Lember and Mattias Bengtsson, and my colleague and friend Bastien Nocera. For Maps, I was also very lucky to get help from an awesome new contributor, Jonas Danielsson. Maps wouldn't look any good without his work.

    Syndicated 2013-10-05 02:49:00 (Updated 2013-10-05 02:49:15) from zeenix

    319 older entries...

    New Advogato Features

    New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.

    Keep up with the latest Advogato features by reading the Advogato status blog.

    If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!