As my Gammu Hackweek 6 project went smoothly, I've decided to spend some time today on phpMyAdmin as well.
My work was mostly inspired by (IMHO unfair) comparing of Adminer and phpMyAdmin. I could surely create similar comparing where would be dozens of things why is phpMyAdmin better, but I don't want to go that way and I rather decided to spend my time on coding.
First and easy task was bit which is in comparing described as "Status variables", where I've added documentation links, so phpMyAdmin now has both short executive summary and link to the official documentation. While looking at server status page, I've categorized some newly added variables, so they now appear in right place. I also reconsidered formatting of numbers and hopefully current solution will work for everybody and not produce contradicting bug reports like the old one.
Then I did focus a little bit on testing AJAX and fixed some minor issues, mostly affecting Chrome/Chromium browsers, because they are strict in case of some errors.
Last but not least I've added URL redirector inside phpMyAdmin, so no external links will now reveal what did user actually was doing in phpMyAdmin, but rather the url of the redirector.
And when speaking about phpMyAdmin, I need to mention one thing as well: contribute yourself! You don't have to be developer, there is currently ongoing themes contest and we're always looking for translators.
Filed under: English Phpmyadmin Suse 0 comments Flattr this!
The government of Egypt has blocked almost all Internet and mobile phone
access,
and, probably, every other form of communication as well. The government wants
to prevent its citizens from protesting and demanding the president to resign.
I wish the people of Egypt well. When the blocks are taken down, I hope
the people report that the country is peaceful and that they have finally
gotten some freedom.
The government of Egypt claims to be democratic, but what they are doing
should not be possible in a democracy. The fundamental
aspect of a democracy is that every citizen should have the right to
vote, but it is not the only necessary right for a democracy. Making
your concerns heard to the government, and to other people, is also
a fundamental right. As is hearing what other people have to say.
Riots and violence are not acceptable ways to protest. Cutting everyone
off is not going to prevent that, however, and it greatly harms any
chance of peaceful resolution. But that's hard to see, when you're
effectively a dictator, sitting at the top of a high tower, looking
down at the common people.
If the government is actively, and violently, hostile towards its people,
the people have three choices: they can submit and accept the situation
and continue suffering; they can oppose peacefully; or they can oppose
violently. It requires great wisdom to oppose peacefully, and quite a lot
of patience.
It's easy, from my northern European point of view, to look at Egypt
from afar, and think lofty thoughts. We here in the cold are not
safe from such oppression, however.
Evil people in the US have already tried to give the US president
similar powers
months ago.
They're trying again.
It is only a matter of time until this will be proposed in the EU, too,
if it hasn't been already.
In a crisis, people need timely access to reliable information, otherwise
the crisis gets made worse by rumors and people making bad decisions
based on bad data. Switching off communications is never the right
solution, from the people's point of view. Those in power
obviously think differently.
See also:
Information on how to bypass some of the blocks in
Egypt.
If There is any sort of food for thought worth reading, this is it.

Hackweek 6 is over and my project is done - Gammu can now talk to Symbian phones. All the work is based on Series60 - remote applet. The changes on Gammu side were not just to implement new protocol, but also some more general improvements it enforced. I think the diffstat summary tells how much was changed:
166 files changed, 23126 insertions(+), 15738 deletions(-)
All code is is available in our Git repository and check documentation for information how to set it up. There will be testing release incorporating these changes next week to give broader audience chance to test it.
So now Gammu has long requested support for Symbian and we need other challenge. That seems to be Android right now and there are already two approaches which might help there. One of them is porting Series60 applet to Android, what is planned by Series60-remote author. There is also other promising way, where I can not share much details right now, but I can give you a little teaser:
$ gammu identify
Device : 192.168.1.4 5210
Manufacturer : HTC
Model : unknown (HTC Nexus One)
Firmware : FRG**
IMEI : **************8
SIM IMSI : **************7
Yes, getting basic information already works for the developer working on it :-).
Filed under: English Gammu Suse 0 comments Flattr this!
It s quite common that the upstream build system generates/updates some files but does not clean them up properly when you call make clean. In that case, when you rebuild the package a second time in the same tree, the generated Debian source package will contain those changes.
You usually don t want those changes. They make your package harder to review because they contain unneeded modifications (either directly in the .diff.gz with the old source format, or in a new patch in debian/patches/debian-changes-<ver> with the 3.0 (quilt) source format).
I ll show you 3 ways to avoid this problem. They are all workarounds, the proper fix would be to improve the upstream build system to really clean up the generated files. This is usually possible for files that are created , but it s much more cumbersome for files that are updated (you would have to keep a backup of the original file so that you can restore it).
The traditional fix
Instead of relying on the upstream build system to do the work, we modify the clean target in debian/rules to remove the files that are left-over. Since debian/rules clean is always called before a source package is built, those generated files are not included as changes compared to what upstream provided.
A common work-around: always build from a clean state
As you have noted, the problem only happens when you build (source and binaries) twice in a row in the same tree. Some VCS-helper tools always build the Debian package in a temporary tree which is exported from the VCS. This is the case of svn-buildpackage by default and of git-buildpackage if you use its --git-export-dir option.
I don t like this solution because it solves the problem only for the maintainer. Anyone else who is working on top of the package without using the same VCS-helper tool would be affected by the problem.
A new way to avoid the problem
Since it s now possible to store dpkg-source options in the source package itself, we can conveniently have everybody use the --extend-diff-ignore option. It tells dpkg-source to ignore some files when checking whether we have made changes to upstream files.
For example if you want to ignore changes made on the files config.sub , config.guess and Makefile you could put this in debian/source/options:
# Don't store changes on autogenerated files extend-diff-ignore = "(^ /)(config\.sub config\.guess Makefile)$"You need to know a bit about Perl regular expressions since that s what is used by dpkg-source to match the filenames to exclude. Note that this approach always works, even when you can t remove the file. So it saves you having to make a backup of the unmodified file just to be able to restore it before the next build.
Found it useful? Be sure to not miss other packaging tips (or lessons), click here to subscribe to my free newsletter and get new articles by email.
No comment Liked this article? Click here. My blog is Flattr-enabled.
... in the world of Belgian Tennis.
I learned yesterday that Justine Henin, ex-number 1 tennis player and
still one of the great talents amongst women's tennis, is forced to stop
her come-back attempt due to an elbow injury which she had been dealing
with since the last Wimbledon.
I don't want to guess what's going through her mind at this point in
time, but it must be terrible. She'd been working so hard for tennis for
all her life, but took a break from the sport because she realized that
she needed to give her life apart from the sport a serious boost. And
when she'd done that and realized that she still loves tennis and wants
to do a come-back, this happens before she'd even been able to
accomplish even one of her goals that she'd set for her come-back.
Terrible.
Justine, on the off chance that you read this: you have my greatest
possible sympathies.
The slightly better news also involves an injury; but this time it's
not a Belgian player, but it involves Venus Williams. Now I'm not one to
gloat at sportspeople's problems, and I do wish Venus all the best and a
speedy recovery; but since her injury means she won't be able to make it
for the Fed Cup tie against Belgium, slightly over a week from now, the
result is that Belgium is now favourite for winning this tie. Of
course, the team can't claim having won until the tie is over, but
hey.
Too bad I can't be there. But there's this other thing that I'm involved with,
which just happens to be in the same weekend. Oh well.
We ve known for a while and want to keep it no longer secret:
New Zealand s famous band The Phoenix Foundation
are in
Europe at the moment, and will come to Switzerland on 17 and 18
February to play in Lausanne and Zurich.
Penny went ecstatic when she
found out and joined the street
team, and we now have no excuses but to go to both shows.
I am certainly looking forward. Even though I haven t really
warmed up to their last two outputs (Buffalo and the Merry
Kriskmass EP), their earlier stuff is heart-warming good-mood music
that should put me back into chilled NZ summer mode. Choice!
NP: The
Phoenix Foundation: Buffalo
For those of you who follow me through anything other than Planet Debian (who will surely tolerate this repetition):
Interesting but frightful things are happening in North African countries. We saw what happened in Tunisia some days ago. Now, Egypt is a way larger, way more populous... And, dare I say, way more important country. Also, it is a country which borders Israel, where I lived in for ~18 months, and to which although I am today unaffiliated is very important for me. And what happens in Egypt will surely shape the whole mid-East.
So, here goes a copy of Mohammed Sameer's post Not just a link to it, as he might have to take it down. Of course, Mohammed, if you in any way think I should delete this, please please tell me, and I will comply immediately.
Egypt has been fighting for freedom already for 3 days now. The whole country has experienced a large number of street demonstrations and protests within the last 3 days to be continued also on Friday, the 28th of January and afterwards. The protests' main goal is to oust dictator Hosni Mubarak's regime, which has been in power for almost 30 years. We want him out. A massacre has happened in Suez. Police used live ammunition and tear gas. There are unconfirmed rumors that the army might interfere. Even a bigger protest is supposed to take place a few hours from now. After the Prayer on Friday. The internet has been shutdown completely. Egypt is no longer online since Friday, the 28th of January 00:45 AM. Text messages to cell phones have been cut off too and all cell phones services will be following. No one knows exactly the intentions of the regime but it doesn't sound good. Please help us....From what I read from Israeli sources, what worries them and many people around the world is that, although Egypt is formally a democratic country, the ruling party has seen towards having basically no oposition Besides the stubborn Islamic Brotherhood (very akin to Hamas). Now, the Islamic Brotherhood (as well as Hamas, and as well as most other Islamic regimes I know off, although I might be way mistaken) have got huge popular support because... They are true to their beliefs. In short, they are not corrupt Something that cannot be said about many political organizations around the globe. They are true to their word. And although many of us shiver at thinking of their word getting more power... It is only the Egyptians who should have a say on who rules Egypt. I honestly hope the Egyptian people get their long-owed self-determination. Of course, I hope Tunisians also get it, and not just a mirage of it. And every people, including us poor Mexicans who have neither had a chance to rule our destiny. And I hope it is a change for good, for tolerance, for peaceful coexistance with the neighbours, even if they are in many ways the rivals. [Update] I just found out that, as expected, the news have reached Slashdot: Egypt shuts off all Internet access. I'm sure you will find lots of more information there.
Please blog about it in English and in all languages.
Please spread the news everywhere.
Please talk to media.
Please petition your government if that will help. If there's anything that you can do, please do it and help us save the country and the people. More news from twitter #jan25.
Egypt has been fighting for freedom already for 3 days now.
The whole country has experienced a large number of street demonstrations and protests within the last 3 days to be continued also on Friday, the 28th of January and afterwards.
The protests' main goal is to oust dictator Hosni Mubarak's regime, which has been in power for almost 30 years.
We want him out.
A massacre has happened in Suez. Police used live ammunition and tear gas. There are unconfirmed rumors that the army might interfere.
Even a bigger protest is supposed to take place a few hours from now. After the Prayer on Friday.
The internet has been shutdown completely. Egypt is no longer online since Friday, the 28th of January 00:45 AM.
Text messages to cell phones have been cut off too and all cell phones services will be following. No one knows exactly the intentions of the regime but it doesn't sound good.
Please help us.
Please blog about it in English and in all languages.
Please spread the news everywhere.
Please talk to media.
Please petition your government if that will help.
If there's anything that you can do, please do it and help us save the country and the people.
More news from twitter #jan25. read more
(Update: Link to Tomeu s blog post, repost for planet.gnome.org)
Last week I was in Prague to attend the GNOME/Python 2011 Hackfest for gobject-introspection, to which Tomeu Vizoso kindly invited me after I started working with PyGI some months ago. It happened at a place called brmlab which was quite the right environment for a bunch of 9 hackers: Some comfy couches and chairs, soldering irons, lots of old TV tubes, chips, and other electronics, a big Pirate flag, really good Wifi, plenty of Club Mate and Coke supplies, and not putting unnecessary effort into mundane things like wallpapers.
It was really nice to get to know the upstream experts John (J5) Palmieri and Tomeu Vizoso (check out Tomeu s blog post for his summary and some really nice photos). When sitting together in a room, fully focussing on this area for a full week, it s so much easier to just ask them about something and getting things done and into upstream than on IRC or bugzilla, where you don t know each other personally. I certainly learned a lot this week (and not only how great Czech beer tastes export GI_TYPELIB_PATH=$HOME/projects/gtk/gtk:$HOME/projects/gtk/gdk export PYTHONPATH=$HOME/projects/pygobjectBetter GVariant/GDBus support The GNOME world is moving from the old dbus-glib python bindings to GDBus, which is integrated into GLib. However, dbus-python exposed a really nice and convenient way of doing D-Bus calls, while using GDBus from Python was hideously complicated, especially for nontrivial arguments with empty or nested arrays:
from gi.repository import Gio, GLib
from gi._gi import variant_type_from_string
d = Gio.bus_get_sync(Gio.BusType.SESSION, None)
notify = Gio.DBusProxy.new_sync(d, 0, None, 'org.freedesktop.Notifications',
'/org/freedesktop/Notifications', 'org.freedesktop.Notifications', None)
vb = GLib.VariantBuilder()
vb.init(variant_type_from_string('r'))
vb.add_value(GLib.Variant('s', 'test'))
vb.add_value(GLib.Variant('u', 1))
vb.add_value(GLib.Variant('s', 'gtk-ok'))
vb.add_value(GLib.Variant('s', 'Hello World!'))
vb.add_value(GLib.Variant('s', 'Subtext'))
# add an empty array
eavb = GLib.VariantBuilder()
eavb.init(variant_type_from_string('as'))
vb.add_value(eavb.end())
# add an empty dict
eavb = GLib.VariantBuilder()
eavb.init(variant_type_from_string('a sv '))
vb.add_value(eavb.end())
vb.add_value(GLib.Variant('i', 10000))
args = vb.end()
result = notify.call_sync('Notify', args, 0, -1, None)
id = result.get_child_value(0).get_uint32()
print id
So I went to making the GLib.Variant constructor work properly with nested types and boxed variants, adding Pythonic GVariant iterators and indexing (so that you can treat GVariant dictionaries/arrays/tuples just like their Python equivalents), and finally a Variant.unpack() method for converting the return value of a D-Bus call back into a native Python data type. This looks a lot friendlier now:
from gi.repository import Gio, GLib
d = Gio.bus_get_sync(Gio.BusType.SESSION, None)
notify = Gio.DBusProxy.new_sync(d, 0, None, 'org.freedesktop.Notifications',
'/org/freedesktop/Notifications', 'org.freedesktop.Notifications', None)
args = GLib.Variant('(susssasa sv i)', ('test', 1, 'gtk-ok', 'Hello World!',
'Subtext', [], , 10000))
result = notify.call_sync('Notify', args, 0, -1, None)
id = result.unpack()[0]
print id
I also prepared another patch in GNOME#640181 which will provide the icing on the cake, i. e. handle the variant building/unpacking transparently and make the explicit call_sync() unnecessary:
from gi.repository import Gio, GLib
d = Gio.bus_get_sync(Gio.BusType.SESSION, None)
notify = Gio.DBusProxy.new_sync(d, 0, None, 'org.freedesktop.Notifications',
'/org/freedesktop/Notifications', 'org.freedesktop.Notifications', None)
result = notify.Notify('(susssasa sv i)', 'test', 1, 'gtk-ok', 'Hello World!',
'Subtext', [], , 10000)
print result[0]
I hope that I can get this reviewed and land this soon.
Thanks to our sponsors!
Many thanks to the GNOME Foundation and Collabora for sponsoring this event!
Third Hackweek 6 day went a bit differently than I planned, but there is still lot of progress.
I've added some more calls to the Series60 remote protocol, so that some things now work much faster (eg. getting number of contacts, calendar entries). The applet now also has a function to toggle Bluetooth so it does not have to be done elsewhere in phone menus.
On Gammu side I focused on messaging support, so now Gammu can list messages in the phone or send new message.
Modification of calendar entries is left for tomorrow, hopefully I will get to it and the support will be more or less complete and I will have Friday for final cleanup.
And as usual - all code is is available in our Git repository and check documentation for information how to set it up.
Filed under: English Gammu Suse 2 comments Flattr this!
Like last year, here s a list of Debian related projects that I d like to tackle this year. I might not do them all, but I like to write them down, I am more productive when I have concrete objectives.
6 comments Liked this article? Click here. My blog is Flattr-enabled.
The easiest way to compress the data that is being served to the visitors of your web application is to make use of mod_deflate. Once you have enabled that module and provided it with a suitable configuration file, it will compress all releant files on the fly as it is serving them.all: build
build:
find static/css -type f -name "[^.]*.css" -execdir yui-compressor -o .css \;
find static/js -type f -name "[^.]*.js" -execdir yui-compressor -o .js \;
cd static/css && for f in *.css.css ; do gzip -c $$f > basename $$f .css .gz ; done
cd static/js && for f in *.js.js ; do gzip -c $$f > basename $$f .js .gz ; done
clean:
find static/css -name "*.css.css" -delete
find static/js -name "*.js.js" -delete
find static/css -name "*.css.gz" -delete
find static/js -name "*.js.gz" -delete
find -name "*.pyc" -delete
Accept-Encoding = gzip,deflate(Incidently, if you want to test what non-gzipped enable browsers see, just browse to about:config and remove what's in the network.http.accept-encoding variable.)<Directory /var/www/static/css>
AddEncoding gzip gz
ForceType text/css
Options +Multiviews
SetEnv force-no-vary
Header set Cache-Control "private"
</Directory>
<Directory /var/www/static/js>
AddEncoding gzip gz
ForceType text/javascript
Options +Multiviews
SetEnv force-no-vary
Header set Cache-Control "private"
</Directory>
I've spent second day of Hackweek 6 on more different tasks.
First I tried to add some improvements to Series60 applet. First things to fix were crashes on requesting non existing contact or calendar entry. After that I started to improve user experience a bit, for example by making the menu work and contain some useful things. After that I've added new functionality to capture screenshots of the device. So you can see how the applet actually looks like:
On the Gammu side, I've implemented reading of contacts and todos. No write support yet, that will be done tomorrow. And of course counterpart for the screenshot function.
I've also spent some time on writing documentation, so now there is some documentation on setting up the S60 connection or the new gammu screenshot command.
All code is is available in our Git repository.
Filed under: English Gammu Suse 0 comments Flattr this!
Next.