You are here

Enrico Zini's blog

Enrico Zini's blog
Checked: 3 years 2 months ago
Updated: 3 years 2 months ago
Update every: 2 hours

Enrico Zini: blog
Subscribe to Enrico Zini's blog

Released cfget 0.8

Enrico Zini's blog - Thu, 29/10/2009 - 2:13pm
Released cfget 0.8

I have released version 0.8 of cfget.

I worked on 3 things:

  • A big cleanup with the excuse of uploading to Debian
  • --root=path to limit queries and dumps to all keys under a given path
  • when used in template mode with an output file name, it will write it atomically.

Released cfget 0.7

Enrico Zini's blog - Wed, 28/10/2009 - 9:57pm
Released cfget 0.7

I have released version 0.7 of cfget.

It adds support for custom configuration file parsers, and some commented example plugins.

Released cfget 0.6

Enrico Zini's blog - Wed, 28/10/2009 - 12:25pm
Released cfget 0.6

I have released version 0.6 of cfget.

This is the first public release.

dput xcowsay_1.1.1_amd64.changes

Enrico Zini's blog - Fri, 23/10/2009 - 8:01pm
dput xcowsay_1.1.1_amd64.changes

dput xcowsay_1.1.1_amd64.changes

Closes: #551864.

It was downloaded from: http://www.doof.me.uk/xcowsay/

Upstream Author: Nick Gasson (also author of the initial Debian packaging, Nick, you rock!)

Building a web-based API with Turbogears2

Enrico Zini's blog - Thu, 15/10/2009 - 1:45pm
Building a web-based API with Turbogears2

I am using TurboGears2 to export a python API over the web. Every API method is wrapper by a controller method that validates the parameters and returns the results encoded in JSON.

The basic idea is this:

@expose("json")
def list_colours(self, filter=None, productID=None, maxResults=100, **kw):
    # Call API
    res = self.engine.list_colours(filter, productID, maxResults)

    # Return result
    return res

To validate the parameters we can use forms, it's their job after all:

Lessons learnt from Oracle

Enrico Zini's blog - Wed, 30/09/2009 - 9:31am
Lessons learnt from Oracle

Lesson number 1: "how to handle temporary files".

$ rm tp*
$ proc code=cpp lines=yes dba_vm.pc 

Pro*C/C++: Release 10.2.0.1.0 - Production on Wed Sep 30 11:10:00 2009

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

System default option values taken from: /usr/local/oracle/10.2.01/db_1/precomp/admin/pcscfg.cfg

$ echo $?
0
$ ls tp*
tpoHRjc8  tpqkU4Cp  tpY5Eo4G
$ 

Pasto criminale

Enrico Zini's blog - Thu, 17/09/2009 - 9:59pm
Pasto criminale

Si era in coda nella circonvallazione di San Giovanni in Persiceto per andare a una visita chirurgica all'USL di Crevalcore, quando si è notato sulla destra questo sbarazzino ristorante con un po' di patacche sulla porta da qualche guida, tra cui pure la Michelin: http://www.ristorantegiardinetto.it/

Firefox garbage collection

Enrico Zini's blog - Tue, 11/08/2009 - 3:47pm
Firefox garbage collection

Some people complained about the insane memory usage of firefox.

It must be a misunderstanding. They probably are not aware of how to trigger the excellent garbage collector shipped with the browser.

Let's navigate heavily a bit, opening several new tabs, click click click around, then closing those tabs:

Released nodm 0.6

Enrico Zini's blog - Mon, 03/08/2009 - 10:34am
Released nodm 0.6

I have released version 0.6 of nodm.

It is purely a bug fix release, trying harder to detect a console in order to get rid of a bug introduced with version 0.5

Released nodm 0.5

Enrico Zini's blog - Fri, 24/07/2009 - 12:29am
Released nodm 0.5

I have released version 0.5 of nodm.

New features:

  • truncate ~/.xsession-errors on startup: finally that file stops growing, and growing, and growing...
  • dynamic VT allocation: it can now avoid opening a virtual terminal if it is already in use.

Debian ssh known_hosts

Enrico Zini's blog - Wed, 22/07/2009 - 11:38pm
Debian ssh known_hosts

Zobel gave me a nice tip.

Step 1:

scp master.debian.org:/etc/ssh/ssh_known_hosts ~/.ssh/debian_known_hosts

Step 2:

Host *.debian.org
        VerifyHostKeyDNS yes
        UserKnownHostsFile ~/.ssh/debian_known_hosts

Step 3: update ~/.ssh/debian_known_hosts every once in a while.

Thank you Zobel, this makes me happy.

Getting dbus signatures right from Vala

Enrico Zini's blog - Wed, 15/07/2009 - 10:30am
Getting dbus signatures right from Vala

I am trying to play a bit with Vala on the FreeRunner.

The freesmartphone.org stack on the OpenMoko is heavily based on DBus. Using DBus from Vala is rather simple, if mostly undocumented: you get a few examples in the Vala wiki and you make do with those.

Released launchtool 0.8

Enrico Zini's blog - Wed, 08/07/2009 - 12:23pm
Released launchtool 0.8

I have released version 0.8 of launchtool. Changes are minor, mostly fixes to the autotools packaging.

It is a good opportunity to document my intentions for future development: launchtool is a bit like start-stop-daemon. The differences are:

Creating pipelines with subprocess

Enrico Zini's blog - Wed, 01/07/2009 - 7:08am
Creating pipelines with subprocess

It is possible to create process pipelines using subprocess.Popen, by just using stdout=subprocess.PIPE and stdin=otherproc.stdout.

Almost.

In a pipeline created in this way, the stdout of all processes except the last is opened twice: once in the script that has run the subprocess and another time in the standard input of the next process in the pipeline.

Anni 80

Enrico Zini's blog - Fri, 26/06/2009 - 3:50am
Anni 80

È morto Michael Jackson.

Manca solo Berlusconi e finalmente siamo fuori dagli anni 80.

Tips on using python's datetime module

Enrico Zini's blog - Thu, 25/06/2009 - 5:18pm
Tips on using python's datetime module

Python's datetime module is one of those bits of code that tends not to do what one would expect them to do.

I have come to adopt some extra usage guidelines in order to preserve my sanity:

Python versione Bignami

Enrico Zini's blog - Thu, 25/06/2009 - 4:13am
Python versione Bignami Tipi di dati

Classici:

Funzioni e classi:

Things you learn while booking a trip to Cacerés

Enrico Zini's blog - Tue, 23/06/2009 - 8:52am
Things you learn while booking a trip to Cacerés
  1. Spain is the only country in Europe that requires the airlines to ask you to enter your document information twice: once in the online check in and once in the "Advance Passenger Information" form.
  2. "Express" buses are more expensive, but at least they are slower.
  3. You only need a EU national ID card to enter the country, but you require a passport to book a bus.
  4. When you click on a form, websites like to reload the current page unchanged, then wait a few seconds to give you time to

Feedback democratico

Enrico Zini's blog - Tue, 09/06/2009 - 8:45am
Feedback democratico

Le elezioni sono passate, la frustrazione rimane.

Per la comodità di chi volesse dare un democratico feedback alle deludenti forze politiche in gioco, dallo spiegare pacatamente le proprie ragioni per l'aver votato un altro, al mandarli cortesemente a scoreggiare nella farina, ecco un po' di email:

Mapping using the Openmoko FreeRunner headset

Enrico Zini's blog - Sun, 07/06/2009 - 9:51pm
Mapping using the Openmoko FreeRunner headset

The FreeRunner has a headset which includes a microphone and a button. When doing OpenStreetMap mapping, it would be very useful to be able to keep tangogps on the display and be able to mark waypoints using the headset button, and to record an audio track using the headset microphone.

Simple tool to query the GPS using the OpenMoko FSO stack

Enrico Zini's blog - Sun, 07/06/2009 - 3:59pm
Simple tool to query the GPS using the OpenMoko FSO stack

I was missing a simple command line tool that allows me to perform basic GPS queries in shellscripts.

Enter getgps:

Voice-controlled waypoints

Enrico Zini's blog - Sun, 07/06/2009 - 12:48am
Voice-controlled waypoints

I have it in my TODO list to implement taking waypoints when pressing the headset button of the openmoko, but that is not done yet.

In the meantime, I did some experiments with audio mapping, and since I did not manage to enter waypoints while recording them, I was looking for a way to make use of them anyway.

Enter findvoice:

Geocoding Unix timestamps

Enrico Zini's blog - Sun, 07/06/2009 - 12:07am
Geocoding Unix timestamps

Geocoding EXIF tags in JPEG images is fun, but there is more that can benefit from interpolating timestamps over a GPX track.

Enter gpxinterpolate:

Recording audio on the FreeRunner

Enrico Zini's blog - Sat, 06/06/2009 - 11:30pm
Recording audio on the FreeRunner

The FreeRunner can record audio. It is nice to record audio: for example I can run the recording in background while I keep tangogps in the screen, and take audio notes about where I am while I am doing mapping for OpenStreetMap.

Here is the script that I put together to create geocoded audio notes:

10 motivi per cui il PD è meglio del PDL

Enrico Zini's blog - Fri, 05/06/2009 - 11:11pm
10 motivi per cui il PD è meglio del PDL

Nel mio piccolo, cerco di dare il mio contributo alla campagna elettorale del PD.

Pages

Subscribe to Enrico Zini's blog