
Ubuntu has had an explicit goal for several cycles now to achieve
flicker-free booting: smooth graphical boot all the way through from
bootloader to the desktop, with no messy modeswitches or cuts between
text and graphics mode on the console. This is no small task, to be
sure; even getting flicker-free transitions between plymouth and X for
the KMS-capable video cards was a handful for 10.04 LTS.
So I was suitably impressed when in the course of testing for the
upcoming
Ubuntu 11.10 release I
found that on a laptop with the nouveau driver, we had achieved 100%
flicker-free boot all the way from grub to X. And then I was astonished
to find the grub-kernel transition was flicker-free when using the
binary nvidia driver too!
This is in large part thanks to Colin Watson's work upstream
implementing VBE support in GRUB2, and Andy Whitcroft's adding proper
support for a vesafb fallback when no KMS video driver is found. The
architecture of how this all hangs together is now documented in the
Ubuntu wiki.
The irony is that, while nouveau gives a perfect flicker-free boot, and
the nvidia binary drivers give a boot with just one modeswitch, both of my
Intel systems show
two modeswitches on boot - one between grub and the
kernel, another between the kernel and X. Something to work on cleaning up
next month, I think...

For
Ada Lovelace Day this year, I want to share my appreciation for Dr. Marian C. Diamond.
In
years past, I ve saluted women in the field of computing, which is my field as well. Dr. Diamond, however, is a biologist. Her research includes neuroanatomy, environment, immune functions, and hormones. In particular, she is interested in studying the effects of the external environment, aging, and immune responses on the cerebral neocortex. She has, in her words, had a
love affair with the brain for about 70 years.
I know very little about biology. The content and methods of her research are, frankly, beyond me, though some of her results have garnered
popular attention. She has inspired me by demonstrating that rare combination of gifts: a deep understanding of a technical subject, and the ability to explain it to other people in an accessible way.
In her interviews, articles and lectures,
many of
which are available online, Dr. Diamond displays these gifts in abundance. Her skill and enthusiasm for both
learning and teaching is unmistakable. After applying her gifts in the classroom for many years, digital distribution has now enabled many more people to see and hear her, through millions of YouTube views.
In 1960, she became the
first female graduate student in UC Berkeley s anatomy department, and was apparently given the job of
sewing a cover for a magnifying machine. I can only imagine the persistence required to continue from there to become a recognized leader in her field. She has gone on to help many other students along their way, and was named an
unsung, everyday hero for the support she provided to students outside of the classroom or lab.
As if that weren t enough, she has also traveled to Cambodia to apply her expertise in
helping children injured by land mines. She still teaches today, just across the bay from where I write this, and will turn 85 next month.
After a little pause, I thought I add another entry to my
ongoing tips
series. Today we'll get rid of the black bars you can most likely observe
on a widescreen display, when playing a video
DVD with
MPlayer.
This little post assumes that you've already inserted the DVD you'd like to
watch, your MPlayer setup works with
dvd:// style addresses, you know
which title from the DVD you want to watch (the examples will use the first
title) and you know your monitor's aspect ratio (the examples uses 16:9).
Now all that is needed are the following two steps:
- Detect the cropping parameters:
mplayer -vf cropdetect -monitoraspect 16:9 dvd://1
The previous line is followed by the usual MPlayer header and output. The
film should start playing and after a few seconds you can press q (just
wait until the detected values stop changing). Now there should be a few lines
looking like:
[CROP] Crop area: X: 0..719 Y: 76..499 (-vf crop=720:416:0:80).
A: 1.5 V: 1.5 A-V: -0.000 ct: -0.018 38/ 38 5% 7% 1.0% 0 0
[CROP] Crop area: X: 0..719 Y: 75..500 (-vf crop=720:416:0:80).
A: 1.6 V: 1.6 A-V: -0.000 ct: -0.018 39/ 39 5% 7% 1.1% 0 0
[CROP] Crop area: X: 0..719 Y: 75..500 (-vf crop=720:416:0:80).
A: 1.6 V: 1.6 A-V: -0.000 ct: -0.018 40/ 40 5% 7% 1.1% 0 0
- Play the film with the detected crop values and the correct aspect for
the video material (4:3 for PAL and 3:2 for NTSC):
mplayer -vf crop=720:416:0:80 -monitoraspect 16:9 -aspect 4:3 dvd://1
Of course you can add any other options to the invocation as usual, though
you only need to add those to the second invocation (e.g. select the correct
audio stream or start in fullscreen mode). Also, you might want to set the
monitor aspect permantly in your MPlayer configuration (just add
monitoraspect = "16:9"), as the monitor rarely changes for the average
machine
/etc/mplayer/mplayer.conf.local is probably the best place
(make sure your
/etc/mplayer/mplayer.conf includes that file at the
end).
Now you should be able to enjoy all video DVDs on your widescreen display
without black bars at the top and bottom!

It's become kind of a clich for me to claim that the reason I'm happy working on ACPI and UEFI and similarly arcane pieces of convoluted functionality is that no matter how bad things are there's at least some form of documentation and there's a well-understood language at the heart of them. My PhD was in biology, working on fruitflies. They're a poorly documented set of layering violations which only work because of side-effects at the quantum level, and they tend to die at inconvenient times. They're made up of 165 million bases of a byte code language that's almost impossible to bootstrap[1] and which passes through an intermediate representations before it does anything useful[2]. It's an awful field to try to do rigorous work in because your attempts to impose any kind of meaningful order on what you're looking at are pretty much guaranteed to be sufficiently naive that your results bear a resemblance to reality more by accident than design.
The field of bioinformatics is a fairly young one, and because of that it's very easy to be ignorant of its history. Crick and Watson (and those other people) determined the structure of DNA. Sanger worked out how to sequence proteins and nucleic acids. Some other people made all of these things faster and better and now we have huge sequence databases that mean we can get hold of an intractable quantity of data faster than we could ever plausibly need to, and what else is there to know?
Margaret Dayhoff graduated with a PhD in quantum chemistry from Columbia, where she'd performed computational analysis of various molecules to calculate their resonance energies[3]. The next few years involved plenty of worthwhile research that aren't relevant to the story, so we'll (entirely unfairly) skip forward to the early 60s and the problem of turning a set of sequence fragments into a single sequence. Dayhoff worked on a suite of applications called "Comprotein". The original paper can be downloaded
here, and it's a charming look back at a rigorous analysis of a problem that anyone in the field would take for granted these days. Modern fragment assembly involves taking millions of DNA sequence reads and assembling them into an entire genome. In 1960, we were still at the point where it was only just getting impractical to do everything by hand.
This single piece of software was arguably the birth of modern bioinformatics, the creation of a computational method for taking sequence data and turning it into something more useful. But Dayhoff didn't stop there. The 60s brought a growing realisation that small sequence differences between the same protein in related species could give insight into their evolutionary past. In 1965 Dayhoff released the first edition of the Atlas of Protein Sequence and Structure, containing all 65 protein sequences that had been determined by then. Around the same time she developed computational methods for analysing the evolutionary relationship of these sequences,
helping produce the first computationally generated phylogenetic tree. Her single-letter representation of amino acids was born of necessity[4] but remains the standard for protein sequences. And the atlas of 65 protein sequences developed into the Protein Information Resource, a dial-up database that allowed researchers to download the sequences they were interested in. It's now part of
UniProt, the world's largest protein database.
Her contributions to the field were immense. Every aspect of her work on bioinformatics is present in the modern day larger, faster and more capable, but still very much tied to the techniques and concepts she pioneered. And so it still puzzles me that I only heard of her for the first time when I went back to write the introduction to my thesis. She's remembered today in the form of the
Margaret Oakley Dayhoff award for women showing high promise in biophysics, having died of a heart attack at only 57.
I don't work on fruitflies any more, and to be honest I'm not terribly upset by that. But it's still somewhat disconcerting that I spent almost 10 years working in a field so defined by one person that I knew so little about. So my contribution to Ada Lovelace day is to highlight a pivotal woman in science who heavily influenced my life without me even knowing.
[1] You think it's difficult bringing up a compiler on a new architecture? Try bringing up a fruitfly from scratch.
[2] Except for the cases where the low-level language itself is functionally significant, and the cases where the intermediate representation is functionally significant.
[3] Something that seems to have involved a lot of putting punch cards through a set of machines, getting new cards out, and repeating. I'm glad I live in the future.
[4] The three-letter representation took up too much space on punch cards

comments

This is my monthly summary of my Debian related activities. If you re among the people who
made a donation to support my work (144.3 , thanks everybody!), then you can learn how I spent your money. Otherwise it s just an interesting status update on my various projects.

Dpkg work
While taking care of the last details for the hardening feature in dpkg 1.16.1, I have
mailed debian-devel to find volunteers to handle a
hardening release goal. The objective is to ensure a large number of packages have been converted/rebuilt to actually use the new hardening build flags.
Then I prepared the draft of the announce of the dpkg 1.16.1 upload (aka
Bits of dpkg maintainers sent to debian-devel-announce) which got expanded by Guillem to also cover new features since dpkg 1.15.7.
update-alternatives got some refactoring by Guillem which resulted in a regression that has been fortunately discovered by Sven Joachim. I fixed that regression and did some further cleanup inspired by the root cause of this regression (see
top 4 commits here).
Note that Sven is one of the few persons who are running the git version of dpkg. Hopefully the number of tester will increase since I recently documented the
APT repositories with autobuilt versions of dpkg in the wiki.
At the end of the month, I started working on a bugfix release (what s going to be 1.16.1.1) by fixing some of the unavoidable problems discovered after an upload that accumulated more than 4 months worth of work (see
top 4 commits here).
The Debian Administrator s Handbook
I spent countless hours finalizing the launch of the crowdfunding campaign for the Debian Administrator s Handbook and it
went live on September 27th.
So far it s on good track with more than 63% of the base funding already secured. But we still have a long way to go to reach the liberation goal (we re at 21%). It s still worth nothing that more than 55% of the money raised has been put in the liberation fund so there are many persons who care about getting the book freed.
More than 250 persons are supporting the project currently with an average contribution of 38 EUR. I would have expected much less for the average contribution but many more supporters. I still hope we can get more people on board with the perspective of a good DFSG-free Debian ebook.

Did you order your copy? If not,
click here and fix this!

By the way Paypal used to be required but it s no longer the case, you can support the project just with your usual credit card.
Misc blog updates
Over time, I have written many useful articles for Debian users and Debian contributors. But scattered in the history, they are somewhat difficult to find. To fix this I have created some index pages listing them. Check them out:
Two new articles joined those pages this month:
How to triage bugs in the Debian Bug Tracking System and
Understand dpkg and don t get stuck with a maintainer script failure.
While writing the first article, I noticed we lacked a good page showing the most buggy packages so I quickly created it (with the help of
UDD):
http://qa.debian.org/cgi-bin/bugs-by-source
Misc packaging work
I did a small update to the developer s reference. Luca Falavigna submitted a patch to clarify how one is supposed to deal with meta-packages (cf
#569219), I improved it and integrated the result in the SVN repository.
I upgraded
nautilus-dropbox to version 0.6.9 and while doing this I discovered a bug in mergechanges (filed as
#640782). I uploaded a new release of quilt mainly to add the Multi-Arch: foreign field so that it can satisfy dependencies of foreign packages (i.e. packages of a different architecture).
Django released some security advisories (tracked in
#641405) and since the maintainer did not deal with the issue, I stepped up to the task (I m a backup maintainer) and released the fixed version 1.3.1 to unstable. I took the opportunity to switch from python-support to dh_python2, and do some misc improvements to the packaging (see
changelog).
I wanted to update
publican to a newer version but it turned out to be not possible because Debian doesn t have the latest version of docbook-xsl yet. I also discovered some bugs in the test suite and forwarded upstream the patch I created (see
upstream bug). On top of this, fop was failing due to some java problem related to the introduction of multiarch. After
having reported the bug, the java maintainers quickly released a fixed version.
So now publican is ready in the git repository but it s waiting on the docbook-xsl update. I got in touch with the maintainer who said he would have the time to take care of it by mid-october.
Thanks
See you next month for a new summary of my activities.
One comment Liked this article? Click here. My blog is Flattr-enabled.

Would MTAs please stop sending hi-bit7 messages
to other MTAs which do not advertise
8BITMIME! Recode it
to QP or BASE64, damnit! The receiving MTA is entitled to strip the
set bit7, which kinda makes things hard to read (while I
know how
to deal with
blvde Stra_e, the advent of UTF-8 makes that
blC6de StraC?e, introduces C0 control characters and makes
typographic quotation marks into NUL-containing octet sequences (as
their UTF-8 representation contains 0x80 octets) which let every
sensible MDA terminate the line there). I even filed in the Debian
BTS against the BTS (might be Drexim's fault, though).
Would MUAs
please default to Quoted-Printable!
And mail hosters should use the same server when retrying delivery,
to benefit greylisting. Or at least publish a list of outgoing IPv4
addresses they use for sending. Or use IPv6. Oh, and
STARTTLS,
while we are on my wishlist.
It's a sad day when the percentage of correctly encoded eMail
messages in my INBOX is smaller than that of my Spambox...

The Ubuntu Technical Board conducts a regular review of the most popular
Ubuntu Brainstorm ideas (previous reviews conducted by
Matt Zimmerman and
Martin Pitt). This time it was my turn. Apologies for the late arrival of this review.
Contact lens in the Unity Dash (
#27584)
Unity supports
Lenses, which provide a consistent way for users to quickly search for information via the Dash. Current lenses include Applications, Files, and Music, but a number of people have asked for contacts to be accessible using the same interface.
While Canonical's DX team isn't currently working on this for Ubuntu 11.10 or 12.04, we'd love somebody who's interested in this to get involved. Allison Randal
explains how to get started, including some skeleton example code and several useful links.
Displaying Ubuntu version information (
#27460)
Several people have asked for it to be more obvious what Ubuntu version they're running, as well as other general information about their system.
John Lea, user experience architect on the Unity team, responds that in Ubuntu 11.10 the new LightDM greeter shows the Ubuntu version number, making that basic information very easily visible. For more detail, System Settings -> System Info provides a simple summary.
Volume adjustments for headphone use (
#27275)
People often find that they need to adjust their sound volume when plugging in or removing headphones. It seems as though the computer ought to be able to remember this kind of thing and do it automatically; after all, a major goal of Ubuntu is to make the desktop Just Work.
David Henningson, a member of Canonical's OEM Services group and an Ubuntu audio developer,
responds on his blog with a summary of how PulseAudio jack detection has improved matters in Ubuntu 11.10, and what's left to do:
The good news: in the upcoming Ubuntu Oneiric (11.10), this is actually working. The bad news: it isn't working for everyone.
Making it easier to find software to handle a file (
#28148)
Ubuntu is not always as helpful as it could be when you don't have the right software installed to handle a particular file.
Michael Vogt, one of the developers of the Ubuntu Software Center, responded to this. It seems that most of the pieces to make this work nicely are in place, but there are a few more bits of glue required:
Thanks a lot for this suggestion. I like the idea and it's something that software-center itself supports now. In the coming version 5.0 we will offer to "sort by top-rated" (based on the ratings&reviews data). It's also possible to search for an application based on its mime data. To search for a mime-type, you can enter "mime:text/html" or "mime:audio/ogg" into the search field. What is needed however is better integration into the file manager nautilus. I will make sure this gets attention at the next developer meeting and filed bug #860536 about it.
In nautilus, there is now a button called "Find applications online" available as an option when opening an unknown file or when the user selects "open with...other application" in the context menu. But that will not use the data from software-center.
Show pop-up alert on low battery (
#28037)
Some users have reported on Brainstorm that they are not alerted frequently enough when their laptop's battery is low, as they clearly ought to be.
This is an odd one, because there are already several power alert levels and this has been working well for us for some time. Nevertheless, enough people have voted for this idea that there must be something behind it, perhaps a bug that only affects certain systems. Martin Pitt, technical lead of the Ubuntu desktop team, has
responded directly to the Brainstorm idea with a description of the current system and how to file a bug when it does not work as intended.
Lintian uses some small scripts to collect data from packages. In daily talk, they are usually referred to as collection scripts. Lintian uses files to track the status of collection scripts between runs. Consider the following directory listing on lintian.d.o:
$ ls -al laboratory/binary/eclipse/.*-*
-rw-r--r-- 1 user group 45 Jul 18 01:21 laboratory/binary/eclipse/.ar-info-1
-rw-r--r-- 1 user group 45 Jul 18 01:21 laboratory/binary/eclipse/.bin-pkg-control-1
-rw-r--r-- 1 user group 45 Jul 18 01:21 laboratory/binary/eclipse/.changelog-file-1
-rw-r--r-- 1 user group 45 Jul 18 01:21 laboratory/binary/eclipse/.copyright-file-1
-rw-r--r-- 1 user group 45 Jul 18 01:21 laboratory/binary/eclipse/.debian-readme-1
-rw-r--r-- 1 user group 45 Jul 18 01:21 laboratory/binary/eclipse/.doc-base-files-1
-rw-r--r-- 1 user group 45 Jul 18 01:21 laboratory/binary/eclipse/.fields-1
[...]
This example shows that a bunch of collections scripts have been run for the eclipse binary package. Each of these files contain the version of Lintian that created them (or last wrote them) and a timestamp.
Why the interest in these files? Let us go a bit back in time to the 15th of June 2011. That was the day where Lintian 2.5.1 was uploaded to unstable. That version of Lintian had 17 collection scripts[1] for binary packages. So every binary package would have 17 files and there are over 35 000 binary packages in the Debian archive.
Ouch, so that makes about 595 000 files if we use this on all binary packages on the archive. The size of each of those files are about 45 bytes, so that is a total of 25.5 MB for all of these files[2]. So other than the inode abuse , this is not too bad. A little
du -h should confirm this
$ du -h laboratory/binary/eclipse/.*-*
4.0K laboratory/binary/eclipse/.ar-info-1
4.0K laboratory/binary/eclipse/.bin-pkg-control-1
4.0K laboratory/binary/eclipse/.changelog-file-1
4.0K laboratory/binary/eclipse/.copyright-file-1
4.0K laboratory/binary/eclipse/.debian-readme-1
4.0K laboratory/binary/eclipse/.doc-base-files-1
4.0K laboratory/binary/eclipse/.fields-1
[...]
Whaaa oh the file system uses a block-size of 4K bytes, so I guess we have to pay a full block for these files. Let s see what that gives, 595 000 times 4 kB is 2.27 GB
Oops!
That was in the (not too distant) past. About a month later (12th of July), the code creating these files are refactored into:
sub _mark_coll_finished
my ($self, $collname, $collver) = @_;
# In the "old days" we would also write the Lintian version and the time
# stamp in these files, but since we never read them it seems like overkill.
# - for the timestamp we could use the mtime of the file anyway
return touch_file "$self-> base_dir /.$collname-$collver";
This turns out to be a very space-saving change if we ask
du -h:
$ du -h laboratory/binary/lintian/.*-*
0 laboratory/binary/lintian/.ar-info-1
0 laboratory/binary/lintian/.bin-pkg-control-1
0 laboratory/binary/lintian/.changelog-file-1
0 laboratory/binary/lintian/.copyright-file-1
0 laboratory/binary/lintian/.debian-readme-1
0 laboratory/binary/lintian/.doc-base-files-1
[...]
Existing files are not emptied, so we still have some old non-empty files left on lintian.d.o. Nevertheless that was the "nice story" about "the side effect of being lazy sometimes reduces space waste"[3].
But we have another "number" problem. If you grep for "Too many links" in the lintian.log from lintian.d.o you should see:
$ grep -i "too many links" logs/lintian.log
mkdir: cannot create directory /srv/lintian.debian.org/laboratory/binary/aces3': Too many links
mkdir: cannot create directory /srv/lintian.debian.org/laboratory/binary/boinc-cgi-stripchart': Too many links
mkdir: cannot create directory /srv/lintian.debian.org/laboratory/binary/libbrailleutils-java': Too many links
mkdir: cannot create directory /srv/lintian.debian.org/laboratory/binary/libbrailleutils-java-doc': Too many links
mkdir: cannot create directory /srv/lintian.debian.org/laboratory/binary/libclippoly0': Too many links
mkdir: cannot create directory /srv/lintian.debian.org/laboratory/binary/libclippoly-dev': Too many links
mkdir: cannot create directory /srv/lintian.debian.org/laboratory/binary/xul-ext-cookie-monster': Too many links
mkdir: cannot create directory /srv/lintian.debian.org/laboratory/binary/cucumber': Too many links
[...]
$ grep -i "too many links" logs/lintian.log wc -l
3274
In the Lintian Laboratory every package is unpacked in a directory based on its type and name (as hinted in the output above). The problem is that ext3 has a limit of the amount sub-directories a directory can have[4]. This limit is just shy of 32 000 and (as a reminder) Debian has over 35 000 binary packages. So a lot of packages are currently not checked on lintian.d.o (
#641468).
The current feature branch for #641468 already solves the directory limit issue (by using a "mirror-like" pool layout). It also removes the need for "1 file per completed collection" by writing this information in the existing "per entry" status file.
I hope we can get the branch merged into master within 2-3 weeks, though there are still a few issues that needs to be worked out before then.
Footnotes:
[1] Actually it had 18 collections, but one of them are "auto-removed" so it is better not to include it in this case.
[2] Content alone - metadata like permissions and such is ignored.
[3] I admit it was more luck than intention!
[4] The limit comes from the "32 000 hardlink per inode" limitation.

We use SugarCRM at work and I've complained about its not-very-RESTy
REST interface. John Mertic a (the?) SugarCRM Community Manager asked
me about what problems I'd had (apart from its lack of RESTfulness)
and I said I'd write a blog post about it.
In our case, the REST interface is used to integrate Sugar and RT so
we get a link in both interfaces to jump from opportunities to the
corresponding RT ticket (and back again). This should be a fairly
trivial exercise or so you would think.
The problems, as I see it are:
- Not REST-y.
- Exposes the database tables all the way through the REST interface
- Lack of useful documentation forcing the developer to cargo cult and
guess
- Annoying data structures
- Forced pagination
My first gripe is the complete lack of REST in the URLs. Everything
is just sent to
https://sugar/service/v2/rest.php. Usually a POST,
but sometimes a GET. It's not documented what to use where.
The POST parameters we send when logging in are:
method=>"login"
input_type=>"JSON"
response_type=>"JSON"
rest_data=>json($params)
$params is a hash as follows:
user_auth =>
user_name => $USERNAME,
password => $PW,
version => "1.2",
,
application => "foo",
Nothing seems to actually care about the value of
application, nor
about the
user_auth.version value. The password is the md5 of the
actual password, hex encoded. I'm not sure why it is, as this adds
absolutely no security, but it is. This is also not properly
documented.
This gives us a JSON object back with a somewhat haphazard selection
of attributes (reformatted here for readability):
"id":"<hex session id>,
"module_name":"Users",
"name_value_list":
"user_id":
"name":"user_id",
"value":"1"
,
"user_name":
"name":"user_name",
"value":"<username>"
,
"user_language":
"name":"user_language",
"value":"en_us"
,
"user_currency_id":
"name":"user_currency_id",
"value":"-99"
,
"user_currency_name":
"name":"user_currency_name",
"value":"Euro"
What is the
module_name? No real idea. In general, when you get
back an
id and a
module_name field, it tells you that the id
exists is an object that exists in the context of the given module.
Not here, since the session id is not a user.
The worst here is the
name_value_list concept which is used all over
the REST interface. First, it's not a list, it's a hash. Secondly, I
have no idea what would be wrong by just using keys directly in the
top level object, so the object would have looked somewhat like:
"id":"<hex session id>,
"user_id": 1,
"user_name": "<username>,
"user_language":"en_us",
"user_currency_id": "-99",
"user_currency_name": "Euro"
Some people might argue that since you can have custom field names
this can cause clashes. Except, it can't, since they're all suffixed
with
_c.
So we're now logged in and can fetch all opportunities. This we do by
posting:
method=>"get_entry_list",
input_type=>"JSON",
response_type=>"JSON",
rest_data=>to_json([
$sid,
$module,
$where,
"",
$next,
$fields,
$links,
1000
])
$sid is our session id from the login
$module is "Opportunities"
$where is opportunities_cstm.rt_id_c IS NOT NULL. Yes, that's
right. An SQL fragment right there and you have to know that you'll
join the opportunities_cstm and opportunities tables because we
are using a custom field. I find this completely crazy.
$next starts out at 0 and we're limited to 1000 entries at a time.
There is, apparently, no way to say "just give me all you have".
$fields is an array, in our case consisting of id, name,
description, rt_id_c and rt_status_c. To find out the field
names, look at the database schema or poke around in the SugarCRM
studio.
$links is to link records together. I still haven't been able to
make this work properly and just do multiple queries.
- 1000 is the maximum number of records. No, you can't say -1 and get
everything.
Why this is a list rather than a hash? Again, I don't know. A hash
would make more sense to me.
The resulting JSON looks like:
"result_count" : 16,
"relationship_list" : [],
"entry_list" : [
"name_value_list" :
"rt_status_c" :
"value" : "resolved",
"name" : "rt_status_c"
,
[ ]
,
"module_name" : "Opportunities",
"id" : "<entry_uuid>"
,
[ ]
],
"next_offset" : 16
Now,
entry_list actually is a list here, which is good and all, but
there's still the annoying
name_value_list concept.
Last, we want to update the record in Sugar, to do this we do:
method=>"set_entry",
input_type=>"JSON",
response_type=>"JSON",
rest_data=>to_json([
$sid,
"Opportunities",
$fields
])
$fields is not a
name_value_list, but instead is:
"rt_status_c" : "resolved",
"id" : "<status text>"
Why this works and my attempts at using a proper
name_value_list
didn't work? I have no idea.
I think that pretty much sums it up. I'm sure there are other
problems in there (such as the over 100 lines of support code for the
about 20 lines of actual code that does useful work), though.
Some years ago I came across a really peculiar newsgroup post. It was not about technicalities of any sort. It was about history. A beautifully written history of computers. From the Turing machine to the Free Software world, the original author managed to capture all the important events of the computer revolution with a great deal of humor. Re-posting it here, it is just brilliant.
The Gospel of Tux (v1.0)
In the beginning Turing created the Machine.
And the Machine was crufty and bodacious, existing in theory only. And von Neumann looked upon the Machine, and saw that it was crufty. He divided the Machine into two Abstractions, the Data and the Code, and yet the two were one Architecture. This is a great Mystery, and the beginning of wisdom.
And von Neumann spoke unto the Architecture, and blessed it, saying, Go forth and replicate, freely exchanging data and code, and bring forth all manner of devices unto the earth. And it was so, and it was cool. The Architecture prospered and was implemented in hardware and software. And it brought forth many Systems unto the earth.
The first Systems were mighty giants; many great works of renown did they accomplish. Among them were Colossus, the codebreaker; ENIAC, the targeter; EDSAC and MULTIVAC and all manner of froody creatures ending in AC, the experimenters; and SAGE, the defender of the sky and father of all networks. These were the mighty giants of old, the first children of Turing, and their works are written in the Books of the Ancients. This was the First Age, the age of Lore.
Now the sons of Marketing looked upon the children of Turing, and saw that they were swift of mind and terse of name and had many great and baleful attributes. And they said unto themselves, Let us go now and make us Corporations, to bind the Systems to our own use that they may bring us great fortune. With sweet words did they lure their customers, and with many chains did they bind the Systems, to fashion them after their own image. And the sons of Marketing fashioned themselves Suits to wear, the better to lure their customers, and wrote grave and perilous Licenses, the better to bind the Systems. And the sons of Marketing thus became known as Suits, despising and being despised by the true Engineers, the children of von Neumann.
And the Systems and their Corporations replicated and grew numerous upon the earth. In those days there were IBM and Digital, Burroughs and Honeywell, Unisys and Rand, and many others. And they each kept to their own System, hardware and software, and did not interchange, for their Licences forbade it. This was the Second Age, the age of Mainframes.
Now it came to pass that the spirits of Turing and von Neumann looked upon the earth and were displeased. The Systems and their Corporations had grown large and bulky, and Suits ruled over true Engineers. And the Customers groaned and cried loudly unto heaven, saying, Oh that there would be created a System mighty in power, yet small in size, able to reach into the very home! And the Engineers groaned and cried likewise, saying, Oh, that a deliverer would arise to grant us freedom from these oppressing Suits and their grave and perilous Licences, and send us a System of our own, that we may hack therein! And the spirits of Turing and von Neumann heard the cries and were moved, and said unto each other, Let us go down and fabricate a Breakthrough, that these cries may be stilled.
And that day the spirits of Turing and von Neumann spake unto Moore of Intel, granting him insight and wisdom to understand the future. And Moore was with chip, and he brought forth the chip and named it 4004. And Moore did bless the Chip, saying, Thou art a Breakthrough; with my own Corporation have I fabricated thee. Thou thou art yet as small as a dust mote, yet shall thou grow and replicate unto the size of a mountain, and conquer all before thee. This blessing I give unto thee: every eighteen months shall thou double in capacity, until the end of the age. This is Moore s Law, which endures unto this day.
And the birth of 4004 was the beginning of the Third Age, the age of Microchips. And as the Mainframes and their Systems and Corporations had flourished, so did the Microchips and their Systems and Corporations. And their lineage was on this wise:
Moore begat Intel. Intel begat Mostech, Zilog and Atari. Mostech begat 6502, and Zilog begat Z80. Intel also begat 8800, who begat Altair; and 8086, mother of all PCs. 6502 begat Commodore, who begat PET and 64; and Apple, who begat 2. (Apple is the great Mystery, the Fruit that was devoured, yet bloomed again.) Atari begat 800 and 1200, masters of the game, who were destroyed by Sega and Nintendo. Xerox begat PARC. Commodore and PARC begat Amiga, creator of fine arts; Apple and PARC begat Lisa, who begat Macintosh, who begat iMac. Atari and PARC begat ST, the music maker, who died and was no more. Z80 begat Sinclair the dwarf, TRS-80 and CP/M, who begat many machines, but soon passed from this world. Altair, Apple and Commodore together begat Microsoft, the Great Darkness which is called Abomination, Destroyer of the Earth, the Gates of Hell.
Now it came to pass in the Age of Microchips that IBM, the greatest of the Mainframe Corporations, looked upon the young Microchip Systems and was greatly vexed. And in their vexation and wrath they smote the earth and created the IBM PC. The PC was without sound and colour, crufty and bodacious in great measure, and its likeness was a tramp, yet the Customers were greatly moved and did purchase the PC in great numbers. And IBM sought about for an Operating System Provider, for in their haste they had not created one, nor had they forged a suitably grave and perilous License, saying, First we will build the market, then we will create a new System, one in our own image, and bound by our Licence. But they reasoned thus out of pride and not wisdom, not forseeing the wrath which was to come.
And IBM came unto Microsoft, who licensed unto them QDOS, the child of CP/M and 8086. (8086 was the daughter of Intel, the child of Moore). And QDOS grew, and was named MS-DOS. And MS-DOS and the PC together waxed mighty, and conquered all markets, replicating and taking possession thereof, in accordance with Moore s Law. And Intel grew terrible and devoured all her children, such that no chip could stand before her. And Microsoft grew proud and devoured IBM, and this was a great marvel in the land. All these things are written in the Books of the Deeds of Microsoft.
In the fullness of time MS-DOS begat Windows. And this is the lineage of Windows: CP/M begat QDOS. QDOS begat DOS 1.0. DOS 1.0 begat DOS 2.0 by way of Unix. DOS 2.0 begat Windows 3.11 by way of PARC and Macintosh. IBM and Microsoft begat OS/2, who begat Windows NT and Warp, the lost OS of lore. Windows 3.11 begat Windows 95 after triumphing over Macintosh in a mighty Battle of Licences. Windows NT begat NT 4.0 by way of Windows 95. NT 4.0 begat NT 5.0, the OS also called Windows 2000, The Millenium Bug, Doomsday, Armageddon, The End Of All Things.
Now it came to pass that Microsoft had waxed great and mighty among the Microchip Corporations; mighter than any of the Mainframe Corporations before it had it waxed. And Gates heart was hardened, and he swore unto his Customers and their Engineers the words of this curse:
Children of von Neumann, hear me. IBM and the Mainframe Corporations bound thy forefathers with grave and perilous Licences, such that ye cried unto the spirits of Turing and von Neumann for deliverance. Now I say unto ye: I am greater than any Corporation before me. Will I loosen your Licences? Nay, I will bind thee with Licences twice as grave and ten times more perilous than my forefathers. I will engrave my Licence on thy heart and write my Serial Number upon thy frontal lobes. I will bind thee to the Windows Platform with cunning artifices and with devious schemes. I will bind thee to the Intel Chipset with crufty code and with gnarly APIs. I will capture and enslave thee as no generation has been enslaved before. And wherefore will ye cry then unto the spirits of Turing, and von Neumann, and Moore? They cannot hear ye. I am become a greater Power than they. Ye shall cry only unto me, and shall live by my mercy and my wrath. I am the Gates of Hell; I hold the portal to MSNBC and the keys to the Blue Screen of Death. Be ye afraid; be ye greatly afraid; serve only me, and live.
And the people were cowed in terror and gave homage to Microsoft, and endured the many grave and perilous trials which the Windows platform and its greatly bodacious Licence forced upon them. And once again did they cry to Turing and von Neumann and Moore for a deliverer, but none was found equal to the task until the birth of Linux.
These are the generations of Linux:
SAGE begat ARPA, which begat TCP/IP, and Aloha, which begat Ethernet. Bell begat Multics, which begat C, which begat Unix. Unix and TCP/IP begat Internet, which begat the World Wide Web. Unix begat RMS, father of the great GNU, which begat the Libraries and Emacs, chief of the Utilities. In the days of the Web, Internet and Ethernet begat the Intranet LAN, which rose to renown among all Corporations and prepared the way for the Penguin.
And Linus and the Web begat the Kernel through Unix. The Kernel, the Libraries and the Utilities together are the Distribution, the one Penguin in many forms, forever and ever praised.
Now in those days there was in the land of Helsinki a young scholar named Linus the Torvald. Linus was a devout man, a disciple of RMS and mighty in the spirit of Turing, von Neumann and Moore. One day as he was meditating on the Architecture, Linus fell into a trance and was granted a vision. And in the vision he saw a great Penguin, serene and well-favoured, sitting upon an ice floe eating fish. And at the sight of the Penguin Linus was deeply afraid, and he cried unto the spirits of Turing, von Neumann and Moore for an interpretation of the dream.
And in the dream the spirits of Turing, von Neumann and Moore answered and spoke unto him, saying, Fear not, Linus, most beloved hacker. You are exceedingly cool and froody. The great Penguin which you see is an Operating System which you shall create and deploy unto the earth. The ice-floe is the earth and all the systems thereof, upon which the Penguin shall rest and rejoice at the completion of its task. And the fish on which the Penguin feeds are the crufty Licensed codebases which swim beneath all the earth s systems. The Penguin shall hunt and devour all that is crufty, gnarly and bodacious; all code which wriggles like spaghetti, or is infested with blighting creatures, or is bound by grave and perilous Licences shall it capture. And in capturing shall it replicate, and in replicating shall it document, and in documentation shall it bring freedom, serenity and most cool froodiness to the earth and all who code therein.
Linus rose from meditation and created a tiny Operating System Kernel as the dream had foreshewn him; in the manner of RMS, he released the Kernel unto the World Wide Web for all to take and behold. And in the fulness of Internet Time the Kernel grew and replicated, becoming most cool and exceedingly froody, until at last it was recognised as indeed a great and mighty Penguin, whose name was Tux. And the followers of Linus took refuge in the Kernel, the Libraries and the Utilities; they installed Distribution after Distribution, and made sacrifice unto the GNU and the Penguin, and gave thanks to the spirits of Turing, von Neumann and Moore, for their deliverance from the hand of Microsoft. And this was the beginning of the Fourth Age, the age of Open Source.
Now there is much more to be said about the exceeding strange and wonderful events of those days; how some Suits of Microsoft plotted war upon the Penguin, but were discovered on a Halloween Eve; how Gates fell among lawyers and was betrayed and crucified by his former friends, the apostles of Media; how the mercenary Knights of the Red Hat brought the gospel of the Penguin into the halls of the Corporations; and even of the dispute between the brethren of Gnome and KDE over a trollish Licence. But all these things are recorded elsewhere, in the Books of the Deeds of the Penguin and the Chronicles of the Fourth Age, and I suppose if they were all narrated they would fill a stack of DVDs as deep and perilous as a Usenet Newsgroup.
Now may you code in the power of the Source; may the Kernel, the Libraries and the Utilities be with you, throughout all Distributions, until the end of the Epoch. Amen.

The MeeGo community is frustrated with the news of the MeeGo brand being abandoned. Some are understandably angry or otherwise not happy about how Linux Foundation, Intel handled the
Tizen announcement and community in general - or more like how they didn't handle it at all.Last week
Openmind 2011 happened to be arranged in Tampere on the very same day as Tizen announcement came alive. It was good in the way that it lead to the fact that
Nomovok's CEO Pasi Nieminen was able to initiate the "
Reigniting MeeGo" session not just by talking vague things about future, but actually about the process which led to Tizen and the unfortunately brief initial PR about it. Pasi is intense on emphasizing the quality and role of
Qt in Tizen as well, even though officially Tizen is all about HTML5 and apparently from Samsung's part at least EFL is provided as a native toolkit. However, the promise of Tizen compared to MeeGo is reportedly that the toolkit is not specified in compliancy documents, so HTML5 with WAC is the main/only "3rd party apps" layer whereas others can be offered case-by-case. This means that unlike before, the underlying system can be built on top of practically any distribution (theoretically) and using whatever toolkits and other techniques wanted. Obviously the "
Nordic System Integrators" are probably all very keen of using Qt to produce more of
Nokia N9 quality user experiences in various products.
Taking the corporate hat off, I as a community member am also puzzled. The only reason I was not completely blown by the news was that I didn't yet manage to get involved in MeeGo community on a daily basis, since I'm involved with a dozen communities already. Instead I've been more like scratching the surface with MeeGo Network Finland meetings, IRC activity, OBS usage for building a few apps for MeeGo Harmattan and MeeGo proper etc. But I can somewhat understand how people like Jarkko Moilanen from meego-fi feel. They have given a _lot_ to the MeeGo community and brand, all taken away without hearing or pre-notice.
So where to now for MeeGo community? Tizen is one obvious choice. However, for all the talks that even I started this post with, Tizen is still vaporware today, and the dislike of how community is being treated might make it easy to consider other options. Also, if Tizen's reference implementation has lesser meaning, it might also mean less to actually be "in" the Tizen community than in MeeGo. I met Jos Poortvliet at Openmind, and he
invited people to openSUSE. There is a lot of common ground with MeeGo and openSUSE - strong OBS usage, RPM packaging, community side focused on KDE and therefore Qt.
I would like to now point similarly to
Debian! If one is tired about corporate interests and not listening to community, there is no match for Debian's 15+ years history, purely volunteer based, trust based organization, and first of all scope. While openSUSE has traditionally focused on desktop (even though like Jos pointed out they are open to all new contributions and projects), Debian has always had the "universal" scope, ie. no boundaries besides producing free software operating system for various purposes. There are over 10 architectures maintained at the moment, including the ARM (different ports for ARMv4 and hard-float ARMv7) and x86 from MeeGo world. There are even alternative kernels to Linux, mainly the GNU/kFreeBSD port. There are multiple relevant plans and projects like the
Smartphones wiki area, most noticeably
Debian on Neo FreeRunner. I have run
Debian on my primary mobile phone for over 2.5 years, although now in the recent months I've had dual-SIM in my Nokia N950 as well (Debian not yet running on Nokia N950 or Nokia N9 - but it can and will be done!).
What Debian may lack in both good and bad is corporate funding, if you don't count the still quite respectful contributions from Ubuntu to Debian (it's in Ubuntu's interests to contribute as much possible back to Debian, so that the delta remains small). For each and every aspect, it needs a volunteer - there are a thousand volunteer Debian Developers, and at least a double of that of people without the official DD status but who still maintain a package or two among the 25000+ packages in Debian. That means also that one my find it more lucrative to join a project that has paid people to do some of the "boring parts", more of fancy web tools, including for bug handling and build systems like the OBS (which I do love by the way). On the other hand, there is no other project in my opinion where what you do really matters as much.
To find out more about Debian from MeeGo perspective, please see the recent mailing list post
Mobile UXes - From the DebConf11 BoF to the stars where I wrote most of the MeeGo (CE) part when I was asked to and known of my MeeGo involvement.
Last but not certainly least, there is the
Mer project - originally "maemo reconstructed", ie. making Nokia's "not really distro" into a real distro by filling in the void places. Now it's obviously MeeGo reconstructed, and they aim to be
the MeeGo they always wanted MeeGo to be! Read the post for details from Carsten Munk and other key Mer people. They share the love for Qt, and want the core to be as lean as possible. They also aim to incorporate the most community like aspect from MeeGo -
MeeGo CE - as the reference vendor in Mer. They also aim to be Tizen compliant - and when Tizen comes alive, I wouldn't see why the Tizen reference implementation couldn't be used for saving resources. Maybe Nomovok and/or others could offer the Qt maintaining part.
So, it might be that Tizen itself is enough for most people's needs. The key point however in this post is not to fall in agony if one corporate based project takes big turns - it has happened before, it will happen in the future. There are always enough political and business reasons from some points of view to do Big Changes. But the wider community is out there, always, and it's bigger than you think. You should consider where you want to contribute by asking yourself why you are/were part of for example the MeeGo community. Aaron Seigo from KDE asked us all this question in the Openmind MeeGo Reignited session, and I think it's good to repeat.

A continuation of my
intermittent series on Emdebian and prompted by a query from
Paul Wise, I thought I'd cover some of the uses to which a device running Emdebian can be put. It is a bit long this one...
So, yes, there are general purpose computers which could run Emdebian but there are common features amongst general purpose computers:
- Lots of different tasks must be supported - lots of different packages installed, each user could quite easily use a distinct set of packages from another user.
- Multi-user support - even if any one machine is only used by one person, a general purpose computer must have support for adding another user - not just a system user, a real user with a login, shell, possibly bookmarks and browser history etc.
- Connectivity - general purpose computers (and that includes mobile phones) must connect to a variety of other computers to be at all useful.
- Multi-modal data input - there needs to be support for a mouse and a keyboard or touchscreen and just as likely, software support for accessibility interfaces like an on screen keyboard and switch inputs.
- Storage for user data - the system admin can't know how much data users are going to add and if it is general purpose, it's probably going to support media players, image viewers, even office software. The data files managed and written by such software tend to be large and tend to accumulate into large collections. This means that a general purpose machine cannot anticipate the full storage requirements, so has to allow plenty of room for user data storage. If there's so much storage space available, why use an OS which is primarily designed to take up less space? Just use the full version, Debian.
Now compare with the common features of special purpose or single-purpose computers:
- Single task only - a splash screen (without support for removal) covers all the boot information, the single task starts as a daemon and if the user quits the task, the task initiates a shutdown, not quit. Every effort is made to prevent the task from exposing the underlying OS, including auto-restarts if it does crash.
- Single-user support - indeed, user is not the typical user. user in this case is a non-login user without a shell, created by the postinst of the task package purely to support running the task without root privileges (because if the task doesn't need privileges, it shouldn't retain privileges).
- Single mode input - don't expect these machines to support 105 key keyboards. You'll be lucky to have 5 keys which are really just buttons. The button won't just enter 'J' into the machine, it will fire off a command to charge your bank or start a drill or shutdown a malfunctioning service. (Each button will often be multi-functional as well, depending on context). Some devices will replace the mouse with a touchscreen but many are fitted in places where touchscreens simply won't survive, where keys have to be able to withstand being submerged in water (or oil) for hours. Many machines simply won't have mouse support at all. Many will not have any typical external connectors. Indeed, units which go into dirty or wet environments certainly won't have standard external connectors of any kind. Think boats and factories. Internal battery packs with custom hot-fit replacements, buttons encased in 4mm of clear plastic, screens viewable only through protective mesh / filters.
- Restricted connectivity - if the task doesn't need networking, no networking hardware is fitted. If the task doesn't need USB, no USB hardware is fitted. If the task doesn't need serial connections, there will probably be an internal serial connector but also a Warranty void if removed sticker. Don't expect an RS232 inside the case either, this will be a flat cable connector which you'll need to attach to a breakout board which correctly connects the cable wires to the RS232 port pins. That mapping is not standardised (why would it? only service engineers are approved to use it.)
- Constrained user data - the task is in complete control and determines what the user can view, store and access. Storage can be expensive and a power drain, so if the task doesn't need Gb of storage, don't fit the machine with Gb of storage. Profit.
So what are these mysterious single-use computers running Emdebian? It's hard to tell because the task has no particular reason to tell the user anything about the OS. Perhaps a different way to phrase the same question would be: Why use a general purpose OS for a special purpose computer?.
- Single task does not mean single process - doing one thing can involve doing a couple of different things behind the scenes, so a multi-tasking kernel and userspace is extremely useful in providing a responsive machine without wasting money on unnecessarily powerful hardware. Multithreading support is also valuable.
- Software reuse makes good business sense - why write a single-usage operating system when the device needs a multi-tasking OS anyway and suitable ones already exist?
- Minimal software - no point packaging Xorg or GNOME when the user interface is a tiny QVGA framebuffer and the device only has 128Mb of RAM. By all means get the core system (cairo, pango, Qt, gettext, dpkg) from Emdebian but the actual code which performs the task of the device will generally be bespoke and, yes, that generally means proprietary, closed source, utterly non-free. This is where GNU/Linux wins over iOS and Windows - the graphical software is trivially separated from the core software and tested as such. If your device has only monochrome text output (and plenty of those still exist), what possible reason is there to use a graphical toolkit? Use the multi-tasking support of the OS to handle inter-process communication and understand the licensing - job done. Again, these devices have deliberately limited storage capacity, the smaller the OS, the lower the cost of the device, within certain constraints.
- Debugging compatibility - this is the big one. It's hard debugging the task software on device with the differences in architecture and connectivity. Why not use the same packages on the same OS on the development machines as on the devices? All the power and all the screen resources to properly investigate bugs, simple way to provide an emulator for translation support and other activities (like user interface training). There will always be bugs which have to be debugged on device - timing issues, hardware issues - but why not make at least a proportion of the likely bugs easier to fix by using binary compatible libraries on both the big desktop machines and the small devices?
This is why Emdebian Grip is popular for these machines - because Emdebian Grip is binary compatible with the equivalent Debian suite and when a bug appears in the high level user interface, it is much easier to debug that on the desktop than on device. Debian stable is a fantastic OS for commercial development - the stability of the OS makes detection of interface bugs much easier. It is rare that developers have to investigate whether bugs in their UI come down to a bug in the underlying OS. That saves time.
The machines themselves? I'm sure others can come up with other examples but these are some which come to my mind (no particular order):
- Control interfaces - solar power controllers, robot controllers - anywhere that a low power board can monitor responses from other machines and do something intelligent about reported errors. Temperature limit responses, pressure limit responses, encoding all of those in assembly or VHDL is hard, so use a system which provides for more creative result handling.
- Electric car charging points - very simple user interface, single task which doesn't complicate things by expecting the user to tap on something to start the main application - just process the card details, charge the customer and provide power.
- Similarlyelectronic point of sale devices - EPOS. The staff on the shop floor don't want to be waiting for an X server to start up and then using a menu. The device starts up and runs one task (checking barcodes, printing labels, counting stock), if the task is shutdown, the machine shuts down.
- Communication aids - my area, a machine which presents a simple UI on non-standard framebuffer hardware, lots of audio output but little other connectivity. Resilience is very important, so solid state is vital but why provide more solid state storage than the device can actually needs?
Anywhere where the device simply needs to DoTheRightThing in a variety of unpredictable circumstances, you're going to need a general purpose OS to gather the data and produce the right result. Anywhere where the device has only a single task, you're going to want to not provide access to the rest of the system. There's no point providing "general purpose access" when the device doesn't have "general purpose hardware". There's no point fitting general purpose hardware if the device does not use it. That is a waste of money, a waste of resources and causes unnecessary delays if one component or other becomes unobtainable or changes behaviour. Limit your exposure to hardware bugs and get the product out to the user more quickly and more reliably, everyone is happy. Fit non-standard hardware and you can fit custom hardware which better matches the profile of the device usage - why use standard speakers capable of CD quality across a vast frequency range when the device only makes very very loud alert noises which can be done at lower sample rates and with narrow range, high amplitude, speakers.
There are all sorts of estimates for the number of computers now in the average Western home. It's worth noting that the vast majority of those computers are not PCs or laptops or even game consoles and routers - all instances of general purpose machines with general purpose access / connectivity. A lot of the computers in your home are embedded in machines like white goods, media controllers (set top boxes and the like). Some of these will still use low level firmware written entirely in assembly or COBOL. More complex ones already have a general purpose OS inside yet constrain that OS with a simple, user-friendly interface which is tailored to the hardware actually fitted. It might be cool to connect to your set top box over Bluetooth but really, is that actually going to sell more units? Only if there are other high-end services written for the device which the average customer won't want to see pushing up the price of the base unit. Some machines (particularly in automotive uses) will need to be using Real Time operating systems and Safety Critical operating systems but even some of those are based on general purpose systems - just old versions which have been thoroughly tested.
Finally, consider that for a lot of these devices, the customer is not you. The customer is another business who then put the device into something else which is installed into a factory production line which produces something which goes into creating a consumer product you find in Tesco or on Amazon or bundled in with another service like your TV/broadband contract. There is absolutely no reason for these devices to provide general purpose computing to you, even if the device itself is part of something else which can provide such services.

The last month I was supposed to work on a
OpenStack related
project, but for administrative reasons it has been delayed and I've tried to
do small tasks to be able to finish them quickly and start the work on the
main project when the issues get solved.
As the delay has been longer than expected last Wednesday I've realized than
on the last weeks I did a lot of small system administration tasks:
- With a co-worker I started to work on a GNU/Linux version of our firewall
based on Shorewall to handle the rules and
conntrackd and keepalived to make it highly
available (I had to stop my work on the
Debian GNU/kFreeBSD based firewall
a long time ago, and this summer the old firewalls' hardware started to
fail, so a migration from Linux to Linux makes sense now, as it will be
faster and a future migration will be simpler, as we will have a cleaner set
of rules and better documentation),
- I installed and configured an instance of a web based File Exchange server
(F*EX),
- I installed and configured an instance of a pastebin clone,
- I installed and configured an instance of ProFTPD that works only
as a SFTP server using virtual users (without shell access),
- I also installed an instance of a web based event management system called
indico that is being used to manage a conference and probably will
be used for other events in the future,
- I installed and patched some plugins in our Trac servers,
- I tried a groupware system called SOGo that we will probable deploy
in a week or two,
- And updated and fixed configurations of some other services,
With all the changes I did I noticed that I had to do something with our
Intranet server; it is just a reverse proxy for a lot of different web
services and its main page was one static HTML page with links to them,
nothing else.
In the long term maybe we will replace it with something based on
Drupal or
Lifeay, but for now I just wanted something to
be able to organize the links and provide some information about the services
for the new users without having to write HTML (I really like
Agile
Documentation Tools that let me focus on the content and forget about
the markup), and started to look at some of them.
My first idea was to use
ikiwiki, as it has all the features I was
looking for: I can use
Markdown or
reStructuredText to
write the contents, the source pages are easily handled on a
Version Control
System, it supports the use of templates for the HTML, etc., but it
seemed to me that using ikiwiki was like
killing flies with a cannon
(that's a Spanish say, I guess it's easy to understand it in English, no?)
and I decided to review other
tools to build static web sites.
To make a long story short, I selected some tools that met my requirements and
looked nice on their demo sites; after my first review I thought that
Hyde was going to be my bet, as it uses technologies I'm already
familiar with, but after trying it I saw that I was going to have a problem
with documentation (the current Hyde version lacks it) and it was going to
be more complicated that using ikiwiki.
Before giving up I decided to review simpler tools, just in case, and after
looking some of them I ended up using
poole, a simple
python script (the source is just one file and it only requires
python-markdown to work).
Before moving to the content I tried to adapt a couple of free themes to be
used by the tool, but I didn't liked the result, so I went back to the plain
style provided by the tool and added a logo and a background.
With that simple look and feel I started to work with the content, splitting
it into eight markdown files and a python macro to include a file that has all
the links used on the site.
While trying to make the main page look good I noticed how little I know about
CSS, but using search engines I was able to build a two column block into the
main page and publish the contents and with the help of some CSS enabled
co-workers I changed the look and feel of the site in about 30 minutes.
In summary, if you want a really simple website, you know a little bit of
python and don't want to spend much time learning how to use a website
generator then Poole is a good option. If you want something more complex
I still think that ikiwiki is a good option, but YMMV.

One of the more classic jokes about not yet understood bugs is that
the
phase of the moon is somehow involved in causing it.
Being bored, I decided to spend some time to see whether "date of bug
filed" could somehow be correlated with "phase of the moon" for a given
source package.
Fast forward an hour of perl experimenting, and here we are:
#!/usr/bin/perl -w
use strict;
use warnings;
use constant PI => 3.1415926535;
use feature "say";
use SOAP::Lite;
use Astro::Coord::ECI::Moon;
my $soap = SOAP::Lite->uri('Debbugs/SOAP')->proxy('http://bugs.debian.org/cgi-bin/soap.cgi');
if (!defined($ARGV[0]))
die "E: must have a source package!\n";
my @bugs = $soap->get_bugs(src=>$ARGV[0])->result();
my $bugsdata = $soap->get_status(@bugs)->result();
my $moon = Astro::Coord::ECI::Moon->new();
my %count = ( 'new' => 0, 'first' => 0, 'full' => 0, 'last' => 0);
foreach my $bug (keys %$bugsdata)
my $time = $$bugsdata $bug -> date ;
my $phase = $moon->phase($time);
if ($phase <= 45 * PI / 180 $phase > 315 * PI / 180)
$count 'new' = $count 'new' + 1;
elsif ($phase <= 135 * PI / 180 && $phase > 45 * PI / 180)
$count 'first' = $count 'first' + 1;
elsif ($phase <= 225 * PI / 180 && $phase > 135 * PI / 180)
$count 'full' = $count 'full' + 1;
elsif ($phase <= 315 * PI / 180 && $phase > 225 * PI / 180)
$count 'last' = $count 'last' + 1;
say "Number of bug submissions during new moon : " . $count new ;
say "Number of bug submissions during first quarter: " . $count first ;
say "Number of bug submissions during full moon : " . $count full ;
say "Number of bug submissions during last quarter : " . $count last ;
This uses the (not packaged in Debian)
Astro::Coord::ECI::Moon
perl module.
Use like so:
wouter@carillon:~code/perl$ ./debbugsmoon nbd
Number of bug submissions during new moon : 2
Number of bug submissions during first quarter: 10
Number of bug submissions during full moon : 1
Number of bug submissions during last quarter : 3
Apparently there's a reasonable correlation between 'the moon is in
the first quarter' and 'people file bugs on nbd'.
Note: no, the above is probably not very
scientific. That's not the point.