Planet Entropia (CCC Karlsruhe)

Harvesting

Apropos

This planet is made of fresh clean feeds by members of the Entropia bunch

The software

The Harvester is made of fresh flesh, clean design by Tigion, hacked-together Ruby scripts by Astro and Atom support by Neingeist

To Be Fed

wget the RSS-1.0 feed!

Questions

Missing something?
Contact Neingeist via Mail or Jabber: neingeist@23bit.net

The Turkey Curse

19.05.2013 12:19:00

Hunde und Katzen essen‎

Letzte Woche war ich seit langer Zeit mal wieder unterwegs im Rheinland (z.B. zur Vorbereitung der SIGINT, verschiedene Treffen im Kontext des Transparenzgesetzes NRW, HV der Drosselkom u.a.), und es gab dabei eine Reihe seltsamer Eindrücke, über die sich gar nicht so einfach schreiben lässt. Einige Sachen zu einer Geschichte muss ich aber dennoch loswerden, auch wenn sie missverständlich oder gar als Angriff ankommen mögen, als das es nicht gemeint ist.

Im NRW-Landtag in Düsseldorf fand auf Einladung der Landesregierung die Veranstaltung Zukunftsforum “Digitale Bürgerbeteiligung” - Open Government und Open Parliament in NRW begreift. Um es gleich klar machen: Ich fand die Veranstaltung im Kern ganz gut und weiss durchaus sehr zu schätzen, was die Landtagsverwaltung NRW auf die Beine gestellt hat. Allerdings hoffe ich, dass bei weiteren Veranstaltungen dieser oder ähnlicher Art die Organisatoren im Detail etwas mehr Fingerspitzengefühl, Humor und Mut entwickeln. Meines Erachtens entspräche das Format wohl eher einem klassischen Barcamp, das etwas mehr Spontanität zugelassen hätte. Trotzdem muss ich sagen, dass ich es als viel offener empfunden habe als erwartet.

Aber wie schon angedeutet gibt es einige Anmerkungen, die ich mir einfach nicht verkneifen kann.

Das Programm startete mit den Eröffnungsreden von Landtagspräsidentin Carina Gödecke und Ministerpräsidentin Hannelore Kraft. Danach ging es direkt weiter mit dem ersten Panel — und was für einem: Dort standen 10 (in Worten zehn) Männer in gleichem Aufzug einer (in Worten: einer) Frau gegenüber. Diese Frau wurde zudem mit den Worten begrüßt: “Nun kommen wir zu unserer einzigen Frau in der Runde. Dafür hat sie aber einen schönen Namen”. Hier ein Screenshot von diesem Teil der Veranstaltung, der durchaus etwas ikonenhaftes hat wie ich finde.

Eröffnungspanel #opennrw

Anmerkung: Dieser Screenshot ist von dem Video des Panels von der Seite der Veranstaltung. Ein anderes Foto, dass ich auf Grund der Lizenz nicht einbinden kann, findet sich bei Flickr.

SRSLY? Im Jahre 2013 findet ein Event zum Thema “Digitale Bürgerbeteiligung” statt und die Veranstalter stellen dort allen Ernstes 10 Kerle und eine Frau auf die Bühne? Das ist irgendwie etwas zuviel Postgender für meinen Geschmack, und überhaupt: Dass eine Veranstaltung zu so einem Thema sogar einen geringeren Frauenanteil aufweist als die üblichen Nerdkonferenzen oder ein durchschnittlicher Parteitag der Piratenpartei, sollte sehr zu denken geben.

Schräg auf dem Panel war übrigens Innenminister Jäger (dritter von links auf obigem Bild) mit dem Spruch “Ich finde, Open Government hat nichts damit zu tun, dem Bürger terabyteweise Daten zuzuschieben”. Doch, lieber Herr Jäger, genau das hat es. Dass der zuletzt durch seinen besonderen Einsatz für die Bestandsdatenauskunft und auch sonst nicht grade als Freund bürgerrechtsfreundlicher Politik bekannte SPD-Minister solche Sachen auf einem Event dieser Art von sich gibt ist schon irgendwie bitter, zeigt es doch, wie wenig ihn das Thema ganz offensichtlich interessiert, sonst hätte er mitbekommen, worum es geht. Sehr schräg war dann auch, dass auf dem Panel über Mails von Mitarbeitern gesprochen wurde, die echt niemanden interessieren, denn darum geht es in der Debatte um Offene Daten nicht und ging es auch nie.

Im Vorfeld der Veranstaltung wurde bereits vor einigen Wochen der Hashtag #opennrw für Twitter öffentlich auf den entsprechenden Seite verkündet und sogar Broschüren mit eben jenem Hashtag gedruckt, woraufhin jemand ein kleines Script geschrieben hat, das Katzenbilder von Google geholt und mit dem entsprechenden Hashtag versehen konstant auf Twitter postete.

Auf dem Event wurde zur Eröffnung verkündet, der Hashtag werde nun auf #opennrw13 geändert und sogleich bekam ich hinter mir ein Telefonat mit, in dem die Worte fielen “Hey, die haben den Hashtag geändert. Hol die Katzen raus!” - wohl in Anlehnung an “Bring out the KRAKEN”.

Cat Attack auf #opennrw und #opennrw13

Symbolbild: Anhaltender Cyberangriff von Katz3n auf #opennrw und #opennrw13

Es gab auf dem Event natürlich auch wenig überraschend “Twitterwalls”, bei denen irgendwann “katzen” und “katz3n” gefiltert wurden:

#opennrw ohne katzen

siehe meinen Tweet dazu: OpenNRW nur ohne Katzen!

Für mich bringt das die Defizite im Umgang mit digitaler Öffentlichkeit wehr gut auf den Punkt, und nicht zuletzt das war ja wohl auch Sinn der Übung wie ich das einschätze. Zumindest aber die Landeszentrale für politische Bildung NRW scheint es mit Humor genommen zu haben und twitterte “Kann einer mal die katze füttern!”. Es sollte tatsächlich einfach als das betrachtet werden, was es ist: Ein vielleicht etwas schräges, aber durchaus herzliches und freundliches Willkommen, ein “wir werden noch viel Spass haben, wenn ihr ein wenig den Stock aus dem Hintern nehmt” und eine Einladung, weiter auf Augenhöhe miteinander zu reden (ja, auch auf Augenhöhe der Katzen, aber den Witz kann keiner kapieren, der nicht in einer konkreten Situation dabei war ^^).

Aber ehrlich: Ich vermute, dass daraus komplett die falschen Schlüsse gezogen werden — was sich ja schon daran zeigt, dass Urheber dieser Aktion anwesend waren (nein, ich war das nicht!), aber weder IRL noch auf Twitter wirklich eine direkte Ansprache stattfand, auf die diese ganz sicher reagiert hätten. Denn das war (und ist) kein anonymer Porno-, Malware- oder Linkspam, sondern freundlich dreinblickende Katzen (und, zugegeben, das eine oder andere Pony, das sich da eingeschlichen zu haben scheint).

Zum Abschluss gab es — Tusch — ein weiteres Panel, dieses Mal mit nur fünf Männern und einer Frau. Schade eigentlich, waren die Workshops im Laufe des Tages doch meist von gutem Niveau, und dieses Panel setze ganz klar falsche Zeichen.

Auch wenn das jetzt etwas merkwürdig rüberkommen mag, dass ich eine Kritik ausgerechnet an dieser einen Frau in der Gruppe richte, muss ich sie dennoch loswerden.

Einmal mehr irritierte mich das Gov2.0-Netzwerk: Deren Vertreterin auf dem Panel ist nicht nur im Vorstand des Vereins, sondern auch Mitarbeiterin bei Dataport, dem Dienstleister der Verwaltungen in den Nordländern. Sie betonte zwar in der Vergangenheit mir gegenüber schon öfter, dort nur als Pressesprecherin zu arbeiten und bezeichnet sich als Journalistin (ich definiere diesen Begriff anders, aber das nur am Rande). Angaben zu diesem Engagement findet sich aber weder auf der Webseite der Veranstaltung, noch wurde darauf bei dem Panel hingewiesen. Das wirkt ähnlich wie bei dem Blogpost Die GovData-Entrüstung…ein Bärendienst? damals, bei der der Auotr der Kritik an der unabhängige Open Data/Open Government-Szene ebenfalls “vergaß” klarzustellen, wie sein persönlicher Kontext ist, wie es in solchen Fällen üblich sein sollte: Er ist NTO (National Technology Officer) bei Microsoft und war ehemals bei CSC, die — Funfact am Rande und unrelated — jetzt grade einen Funktionstest des Staatstrojaner durchführen soll. Einen NGO zu benutzen, während man gleichzeitig in Unternehmen arbeitet, die in dem Bereich tätig sind, den man da vertritt, ist mehr nur ein bisschen bemerkenswert und hatte ich auch schon während meines re:publica-Vortrages mit Lorenz thematisiert.

Grade innerhalb dieser Szenerie, die sich der Öffnung politischer und verfahrenstechnischer Prozesse verschrieben hat, ist Transparenz von ganz besonderer Bedeutung — auch wenn das die Beteiligten ganz anders sehen und sich z.B. bei Facebook darüber mokieren, diese Klarstellungen empfänden sie als störend (Sorry, ich habe keinen Facebook-Account mehr um darauf zu verlinken). Die Entscheidung und Bewertung darüber obliegt ihnen meiner Ansicht nach aber gar nicht (was ich auch schon öfter betont habe). Wenn sie also über den vielbeschworenen “Kulturwandel” reden wollen, ist das eben auch ein Teil dieser neuen Kultur: Klare Ansagen bei möglichen Interessenskonflikten, wie sie ja ganz offensichtlich existieren. Diese ergeben sich ganz automatisch durch Arbeitverträge in ganz besonderer Weise, werden dadurch doch die Kritikfähigkeit und -möglichkeit ganz erheblich eingeschränkt ist. Das zeigt sich dann ja auch in eher nichtssagenden Statements auf diesem Panel. Es sei aber auch noch einmal klar gestellt, dass es nicht als fachliche Kritik gemeint ist, und ich halte die Personen durchaus für kompetent.

Im Chaosdorf wurde der Abend beendet mit Kurzvorträgen zu ZFS, Arbeitsschutz, DNS und Ideen für eigene Verschlüsselung und anschliessendem Konsum von Barbarella und Sachen wie Smells Like Humppa von Eläkeläiset, was speziell an diesem Tag ganz besonders das zum Ausdruck gebracht hat, wie ich einige der Inszenierungen empfunden habe — von gleich mehreren Seiten.

Als ich dann irgendwann spät nachts nach “opennrw” bei Google gesucht habe, bekam ich als Antwort folgende Seite, dessen Werbeblock an Ende der Seite mich zu dem Titel des Posts inspirierte und mich quasi dazu zwang, das ganze einfach mal kurz niederzuschreiben. Man muss sich einfach klar machen, was öffentlicher Raum im Netz momentan bedeutet und wie weit wir von dem entfernt sind, was es sein sollte. Oder wie ich in meiner Kirchentagsrede sagte: “Der öffentliche Raum, über den wir hier reden, ist eher mit einem Kaufhaus zu vergleichen, in dem wir uns treffen und austauschen. Niemand würde das in der Realität ernsthaft als öffentlichen Raum in dem Sinne begreifen, wie wir ihn sonst ganz selbstverständlich wahrnehmen, sondern als das was es ist: Ein privater Raum mit öffentlicher Begängnis”. So verwundert es eben auch nicht, womit der Begriff “OpenNRW” aus Sicht der Werbenden zusammenhängt.

Hunde und Katzen essen!

Mal davon abgesehen, dass ich gelernt habe, es sei in Schweiz völlig normal, Hunde und Katzen zu essen: Erlebnisse an Tagen wie diesen sind es, warum ich dieses Internet einfach von ganzem Herzen liebe!

mehr...

The Turkey Curse

14.05.2013 11:11:00

Adblocking ist ein Sicherheitsthema

Lieber Stefan,

ich schreibe dir, weil ich eine Sache klarstellen möchte: Ich blocke Werbung nicht, weil mich Werbung nervt (ich sehe die nicht mehr) oder euch um eure Einnahmen zu bringen will, sondern weil die Werbung über JavaScript von für mich alles andere als vertrauenswürdige Drittanbieter ausgeliefert wird. Ich weiss durchaus guten Journalismus zu schätzen, weiss, dass dieser nicht umsonst zu haben ist und habe vermutlich mehr Verständnis für die Probleme der Verlage als viele andere denke ich.

Trotzdem kann ich nicht zulassen, dass irgendwelche Buden, die sich regelmässig pwnen lassen, meinen Rechner fernsteuern - denn das und nur das ist JavaScript: Remote Control eines Browsers durch den Server. Dieses Blocking ist also in erster Linie reiner Selbstschutz und ist auch jedem Nutzer sehr zu empfehlen.

Die Historie schädlicher Werbebanner auf Medienseiten ist lang und hat so ziemlich viele schon einmal irgendwann getroffen, sei es Zeit, Spon, Heise oder Handelsblatt um nur mal ein paar zu nennen, über die Schadcode verteilt wurde. Ein Problem ist dabei auch nicht zuletzt, dass es in so einem Falle ausser einer Entschuldigung keinerlei Entschädigung für die Opfer dieser Angriffe gab und gibt (sofern die Leute überhaupt merken, dass die gehackt wurden).

Ich bin nicht die Person, die tolle Ideen für Geschäftsmodelle hat, die funktionieren. Ich würde mir etwas wünschen, das für eure Branche nicht in Frage zu kommen scheint: Sowas wie eine Pauschale für alle Publikationen - in etwa nach dem Modell der GEZ für die Öffentlich-Rechtlichen. Ich nutze die Angebote eher sporadisch (meist auf Grund von Links), “blättere” aber praktisch auf den Seiten nie rum, womit ein Abo für mich keinen Sinn ergibt. Diese Art der Zahlung würde mir in meinem Nutzungsverhalten entgegen kommen.

Micropayment ist leider in den letzten Jahren nicht wirklich weiter gekommen und ausser Flattr sehe ich momentan wenig. Ich verstehe aber auch, dass sich damit kein Journalismus auf hohem Niveau lange finanzieren lässt.

Wie auch immer: Die Verantwortung für meine Sicherheit kann nur ich übernehmen - kein Staat, kein Verlag, kein Journalist und keine guten Worte. Die Konsequenz ist also, dass die Werbung, so auf die nicht verzichtet werden kann, entweder so eingebunden wird, dass sie ohne JavaScript auskommt oder sie wird schlicht geblockt. Denn mir ist Information zwar äusserst wichtig, aber nicht wichtiger als meine Sicherheit.

Mit freundlichen Grüßen, fukami

mehr...

nomeata’s mind shares

11.05.2013 10:26:00

How to play Rock-Paper-Scissors online?

There was an interesting question by ‘Fool’ recently on the StackExchange site for Boardgames: How do you play a game like Rock-Paper-Scissors with friends online? Or any other game where players have to simultaneously submit their moves (e.g. Diplomacy, or Rock-Paper-Scissors-Lizzard-Spock), which, as I just learned, are simultaneous action selection games. While there are websites dedicated to playing specific games, such as webdiplomacy.net, we could not find a generic one that you can use if you, for example, invent your own variants of a game.

So I created one: At you-say-first.nomeata.de you can enter rooms and share the URL with your friends. On the one hand, you have a regular chat room there. But there is also the possibility to enter moves (whatever a move may be to you) and only when all players have done that and marked the move as final, it is shown to everyone. If you want to try it out: There is an integrated, not very fancy Rock-Paper-Scissors-playing bot. Just enter a room, join and say „I want to play!“

Note that this site can be used for more than just for games. Have you ever observed that persons would often want other to express their preference (e.g. where to dine) first to not reveal their own preference, so that they can (or pretend to) change their mind if they would contradict? In such situations simultaneous action selection can be a fairer method.

A technical note: I created this web app using meteor (a JavaScript framework building on node.js and MongoDB that allows for reactive programming), and it is also hosted on meteor.com. I chose Meteor after someone mentioned Firebase to me, which looked very slick, but was not Free Software, so I looked for alternatives. I did not do any cross-browser-testing, and the UI design could be improved, so if you want to help out (or just complain), please use the GitHub code repository and issue tracker.

mehr...

Hanno's blog

09.05.2013 13:44:00

In eigener Sache - Umbau

Seit 2004 existiert nun dieses Blog von mir. Zeitweise viel genutzt, zeitweise weniger und in letzter Zeit kaum noch. Ein privates Projekt, ein Ort, an dem ich schreiben konnte was ich wollte.

Zwischenzeitlich hat sich bei mir einiges geändert. Ich schreibe weiterhin viel und gern, aber selten hier. Ich bin inzwischen primär als freier Journalist tätig und meine Texte können unter anderem bei der taz, bei Golem, bei Telepolis und gelegentlich sogar bei Zeit online gelesen werden. Mein Blog entwickelte sich zum unpassenden Relikt, gleichzeitig habe ich das Gefühl, dass ich endlich eine Selbstdarstellungsseite für meine journalistische Arbeit benötige und mein Blog dafür in seiner aktuellen Form denkbar ungeeignet ist.

Deshalb wird jetzt hier umgebaut. Mein Blog soll weiter existieren, zum einen natürlich als Archiv und zum anderen soll es nicht ganz sterben. Es wird immer wieder Anlässe geben, die für einen Blogeintrag besser geeignet sind als für einen journalistischen Text. Und wer weiß, je nach Laune wird es vielleicht auch wieder lebendiger.

Das Blog wird künftig unter blog.hboeck.de beheimatet. Abgesehen von der Startseite werden alle alten Links umgeleitet. Probleme bereiten könnte das für manche Feedreader und Aggregatoren. Alles, was HTTP-Redirects versteht, sollte weiter seine Inhalte finden.

Unter der Hauptdomain hboeck.de soll dann irgendwann ein Überblick über meine journalistische Arbeit zu finden sein. Vorerst gibt's hier auch schon eine notdürftige Übersicht über von mir verfasste Beiträge in anderen Medien.
mehr...

nomeata’s mind shares

24.04.2013 11:36:00

The carbondioxide footprint of Debian's Haskell packages

By now, Debian ships quite a lot of Haskell packages (~600). Because of GHC's ABI volatility, whenever we upload a new version of a library, we have to rebuild all libraries that depend on that. In particular, if we upload a new version of the compiler itself, we have to rebuild all Haskell library packages. So we have to rebuild stuff a lot. Luckily, Debian has a decent autobuilding setup so that I just need to tell it what to rebuild, and the rest happens automatically (including figuring out the actual order to build things).

I was curious how much we use the buildd system compared to other packages, and also how long the builders are busy building Haskell packages. All the data is in a postgresql database on buildd.debian.org, so with some python and javascript code, I can visualize this. The graphs show the number of all uploads by autobuilder on the amd64 architecture, with haskell uploads specially marked, and the second graph does the same for the build time. You can select time ranges and get aggregate statistics for that time span.

During the last four days a complete rebuild was happening, due to the upload of GHC 7.6.3. During these 2 days and 18 hours building 537 packages took 48 hours of build time and produced 15kg of CO2. That is 94% of all uploads and 91% the total build time. The numbers are lower for the whole of last year: 52% of uploads, 31% of build time and 57kg of CO2. (The CO2 numbers are very rough estimates.)

Note that amd64 is a bit special, as most packages are uploaded on this architecture by the developers, so no automatic builds are happening. On other architectures have, every upload of a (arch:any) package is built, so the share of Haskell packages will be lower. Unfortunately, at the moment the database does not provide me with a table across all architectures (and I was too lazy to make it configurable yet).

mehr...

NervengiftLabs

25.03.2013 13:01:00

API der Karlsruher Verkehrsbetriebe

Dieser Beitrag interessiert wahrscheinlich hauptsächlich die Karlsruher Leser…

Die Karlsruher Verkehrsbetriebe (KVV) stellten vor kurzem ihre für Smartphones optimierte Web-App vor, mit der man u.a. live Abfahrtsdaten für  alle Haltestellen bekommen kann.

Aber eigentlich will man ja eine API haben, um selbst mit den Daten zu spielen…

Da das ganze natürlich mit AJAX funktioniert kann man schön mitlauschen, wen man was fragen muss, um selbst an diese Daten zu kommen. Es stellte sich sogar raus, dass mein erster Versuch, nämlich die Kommunikation via Wireshark mitzuschneiden, schon Overkill war, denn es handelt sich um reine GET-Anfragen, der API-Key wird als Parameter übergeben. Steht alles im Quellcode der Seite :)

Ich hab mich dann gleich mal drangemacht, die API ein bisschen zu dokumentieren und Python-Bindings zu schreiben. Gibt’s beides auf meinem Github.

Wenn jemand Bindings für andere Sprachen oder coole Statistik-Tools baut, darf er mir die gerne verlinken :)

mehr...

Wenger Online#Blog

23.03.2013 18:33:42

Reise nach Anshan, Liaoning, China

Ich war eine Woche geschäftlich in Anshan in der Provinz Liaoning in China. Anshan ist für chinesische Verhältnisse eine kleine Stadt mit *nur* etwas mehr als 3 Millionen Einwohnern. Der nächste international erreichbare Flughafen ist in Shenyang von wo aus es noch etwas mehr als eine Stunde mit dem Auto bis Anshan ist.

Für eine Reise nach China benötigt man ein Visum welches man nicht zu knapp vor der Reise besorgen sollte, die eigentliche Einreise geht dann recht unspektakulär über die Runde, man füllt noch im Flugzeug einen Einreisezettel mit der Hoteladresse aus und wird nach einem kurzen Blick in den Ausweis durch den Zoll gewunken.

Als ich in Anshan angekommen war, fehlten mir und noch drei weiteren Reisenden aus Deutschland das Gepäck. Trotz der sehr hilfsbereiten Flughafenmitarbeiter war es nicht gerade einfach die notwendigen Anträge zur Gepäcksuche auszufüllen, da niemand im ganzen Flughafen mehr als 2 Worte englisch sprechen konnte. Im laufe des Abends wurde das Gepäck irgendwo wiedergefunden und am darauffolgenden Tag direkt in das Hotel geliefert.

Ich übernachtete, wie schon bei früheren Besuchen, im Wu Huan Hotel. Die Eingangshalle strotzt China typisch nur so von Marmor, Gold und Glitzer. Der Rest vom Hotel ist im gleichen Stil gebaut, doch vielen Ecken sieht man deutlich an das seit dem Bau wohl noch nie etwas renoviert wurde.

Ganz oben im 27ten Stock gibt es morgens immer das Frühstück und wenn man Glück hat die aufgehende Sonne über der Stadt. Leider ist es schwierig schöne Bilder von hier oben zu machen, da die Fenster wohl länger nicht mehr geputzt wurden.

Trotz der ganzen Arbeit war es mir möglich an einem Tag die größte Jade Buddha Statue der Welt zu besuchen. Der Tempel liegt direkt am Rande der Stadt neben einem riesigen Park.
Blick vom Hotelzimmer DSCF1042 DSCF1046 DSCF1047 DSCF1048 DSCF1057 DSCF1058 DSCF1063

mehr...

Wenger Online#Blog

15.03.2013 17:00:46

CNC Sticken II

 

Trauriger Roboter für ein T-Shirt. Vorlage, von Hand reduziert auf wenige Farben und komplizierte Details vereinfacht. Beim ersten Sticken habe ich vergessen zusätzlich dieses Stickfließ unterzulegen und es hat mir ganz viele Löcher in den Stoff gestickt. Leider war das T-Shirt dann nicht mehr zu retten, der zweite Versuch hat dann schon besser geklappt.

Sad Robot - Vorlage SAM_1679 SAM_1681 SAM_1684 SAM_1685 SAM_1686
mehr...

Hanno's blog

05.03.2013 20:44:00

Questioning copyright treaties

Yesterday, I read a news about the green party's proposals for a copyright reform (strictly speaking, there's no copyright in Germany, it's called "Urheberrecht", but I'll stick with the term copyright, because it's commonly understood). One point was that they claimed they don't see any perspectives for a so-called cultural flatrate due to EU law. The basic idea of a cultural flatrate is that it would legalize private filesharing while putting a fee on internet access.

My point is more the reasoning than the issue itself. Because that's a repeating pattern. Whenever someone makes a proposal to change something relevant in copyright or patent law, this is pretty much always the conclusion: It's not possible due to one or another international law or treaty. The discussion ends before anyone can make any real argument why some copyright change might be a good idea or not.

The EU directive that, according to the green party, forbids a cultural flatrate is the EU Copyright Directive from 2001. This directive is itself an implementaiton of the WIPO Copyright Treaty from 1996.

Other treaties that are often relevant are the Berne Convention and the TRIPS Agreement of the WTO from 1994.

What all of those treaties have in common and what I find - in its combination - very troubling:
  • They've been created at a time where many people affected by it today weren't allowed to vote or even weren't born.
  • They were created in a time where the Internet as we know it today and the issues related to it simply didn't exist.
  • It's hard to impossible to change those treaties.
  • There has never been a wide public discussion about any of those treaties, the terms TRIPS, Berne Convention or WIPO copyright treaty are mostly unknown to the general public.
To put it simply: There's something terribly wrong. In so many ways. As I already said above, this is not about the question whether the cultural flatrate is a good idea. It's about the fact that it's almost impossible to make any proposal for a change in the way copyright works. That can't be good, no matter how you feel about copyright issues in general.
mehr...

halcy.de v4

19.02.2013 20:11:00

There is no Cyberwar

Recently, there has been widespread hysteria about the Chinese government, like the governments of the United States of America and Israel and Russia before it, possibly endorsing or supporting people breaking into other peoples computer systems. In the light of the panic being spread by people for whom a general state of fear about foreign people breaking into your computers might be advantageous, it is important to remember one thing:

There is no Cyberwar. Cyberwar is not a thing that is happening anywhere or at any time, nor is it a thing that has ever happened. It is not a thing that is likely to happen in the near future.

Lets break the word “Cyberwar” down into parts. It is made from the word “Cyber”, a prefix used by people who are not competent with computers to mean “Computer things we do not understand”, and “War”, which is generally understood to mean “violent conflict between nations”, or at least “violent, armed conflict”. The kind of conflict where destruction is widespread and people die.

You might have noticed that we haven’t really seen anyone dying from supposed “Cyberwarfare” - at best, there has been economic damage from IP violations, and some breakage of Iranian centrifuges - arguably the most war-like “act of cyberwarfare” to date, and funnily enough perpetrated by the people who are now crying the loudest about it.

That there is no cyberwar does not, by any means, mean that there is no computer crime. There is stealing of industrial secrets, there is mass spamming and scamming, there is all around virus writing and breaking into computer systems by criminal organizations.

Which brings us to the actual, important point: Computer crime is a real, existing, hard to solve problem. Which is exactly why the panic about “Cyberwar” is so harmful - it distracts from the problems we actually have, in lieu of problems that are for the most part made up or actually created by the measures that are supposedly taken to prevent them.

There is no Cyberwar, but if a general and a bunch of politicians on a power trip create a “Cyberwarfare Division”, there suddenly is a whole lot more people writing malware and doing things that destabilize the internet and hurt the network as well as society as a whole. There suddenly is pressure on security professionals to let some malware slide and to build backdoors into their systems, which invariably get abused or introduce new security vulnerabilities. There suddenly are people selling “security consulting” to scared companies, making sure they are protected against a threat that for the most part just doesn’t exist while leaving their systems open to the more everyday, less sexy security problems that cannot be solved by applying quickfixes at 90USD/hr.

It is 2013, computer security is not a thing that is solved or can be solved easily, and the “Cyberwar” hysteria is making it worse. So please: Stop. Stop panicing about Cyberwar. There is no Cyberwar, and the panic about Cyberwar is harmful and in the way of making actual progress towards getting more in control of problems we actually have.

mehr...

nomeata’s mind shares

06.02.2013 09:33:00

Evaluation-State Assertions in Haskell

I have just uploaded a new version of ghc-heap-view to Hackage that provides “Evaluation state assertions” in the module GHC.AssertNF.

Imagine you are writing a web application in Haskell that sports a global number-of-visitors counter in an IORef Int. For every request, you call modifyIORef (+1). Eventually, you notice your very popular web site to hog more and more memory. So you browse to the internal page that shows the counter, and you have to wait for a long time until you eventually see the result (or get a stack overflow). The reason: The applications of  (+1) were not performed until you looked at the number; instead, a long chain of such computation first filled your heap and then your stack.

So you have learned the hard way that you might want to avoid space leaks, and want calculations to be done during the request that caused them, and want the IORef to always contain fully evaluated data. So you stumble about modifyIORef' in Data.IORef and indeed, this fixes your problem.

Later, you notice that you want to count POST and GET requests separately. You change the type to IORef (Int, Int) and call modifyIORef' (first (+1)) or modifyIORef' (second (+1)). And suddenly, the space leak is back (which you only notice after the next push to the real site, because your local tests never caused enough requests to make it noticeable). So you not only want to fix it, you also want to ensure that it does not break again.

In other words, you want to ensure the policy that values stored in an IORef are always in normal form. You achieve this with the following alternative to modifyIORef':

modifyIORef'Assert :: IORef a -> (a -> a) -> IO ()
modifyIORef'Assert ref f = do
    x <- readIORef ref
    let x' = f x
    x' `seq` return ()
    assertNF x'
    writeIORef ref x'

Using this instead of modifyIORef' will print this warning to standard error output right the first time you call modifyIORef'Assert (first (+1)):

Parameter not in normal form: 2 thunks found:
let x1 = (S# 1,S# 1)
in _bh (_thunk x1 (_bco (S# 1)),_sel x1)

(Otherwise, the program runs as usual.) So obviously, you need to use a strict variant of first (or strict pairs):

first' :: (a -> b) -> (a, c) -> (b, c)
first' f (x,y) = let { x' = f x; r = (x', y) } in x' `seq` r `seq` r

With this, the warning goes away. Whenever you now change the type of the IORef or modify it in a too-lazy-way, you can be sure that you’ll be warned about it, before the space leak itself becomes noticeable.

In the production code, you might want to disable the check. For that, simply put disableAssertNF somewhere in your main function.

Why is this better than just calling deepseq in modifyIORef'Assert? Because this way, the code still creates unwanted thunks that are then evaluated before storing them in the IORef, whereas with assertNF you are told about the thunks and can prevent them from being created in the first place. Also, assertNF does not add a type class constraint.

This is just one example application for assertNF (and its variants assertNFNamed, which includes a name in the warning to better spot the cause, and $assertNFHere, which uses Template Haskell to include the current source code position in the warning), and I hope that there are more. If you happen to make use of it, I’d like to hear your story.

mehr...

Wenger Online#Blog

03.02.2013 21:32:18

CNC-Sticken

Zu Weihnachten habe ich mir eine Stickmaschine geschenkt. Eine Brother Innovis 900. Mit einem XY-Tischchen kann diese bis zu 10x10cm, mit einem Trick auch bis zu 10x20cm, große Bereiche besticken. Über einen USB Anschluß auf der Seite kann man eigene Bilder in die Maschine laden.

Der Geburtstagswunsch unseres Sohnes war nun der Anlaß diese Funktion endlich mal genauer unter die Lupe zu nehmen.

Davor kommt aber erst der beschwerliche Weg das gewünschte Bild ins passende Format zu bringen. Da wir beim Sticken nicht 300 mal die Fadenfarbe wechseln wollen ist es wichtig sich auf möglichst wenige Farben zu beschränken. Die meisten Bilder, auch wenn sie auf den ersten Blick so aussehen als ob sie nur aus wenigen Farben bestehen, haben an den Übergängen ganz viele zwischen Farben.

Für dieses Bild (weil es Comicartige schwarze Ränder um jeden Farbbereich hat) war es die beste Methode das Bild zuerst in Scharz-Weiss zu wandeln und dann die Flächen wieder mit dem Floodfill werkzeug zu füllen.

Normale Bilder und Zeichnungen sind als sogenannte Bitmaps gespeichert. Das heisst für jeden Bildpunkt ist gespeichert welche Farbe er hat, aber es gibt keine Information darüber welche Bildpunkte zum Beispiel eine Linie oder Fläche bilden. Damit ein Bild gestickt werden kann muss diese Information zuerst wieder gewonnen werden, das nennt man vektorisieren. Die meisten Stickprogramme haben dazu eine entsprechende Funktion, hier können dann noch Details eingestellt werden. Zum Beispiel wie genau die Vektoren sich an kleine Zipfel annähern sollen und welche Farben gestickt werden sollen.

Da das Motiv auf einen dunklen Stoff gestickt werden soll, habe ich die äußeren schwarzen Ränder teilweise entfernt, besonders zwischen den Haarsträhnen. Bei einem Test war der schwarze Rand da viel zu dominant. An vielen Stellen können gleichfarbige Flächen allein durch eine Änderung der Stickrichtung sichtbar gemacht werden.

Das Resultat sieht ganz gut gelungen aus, nur die gefüllten Flächen sind leider etwas zu klein geworden, so daß zwischen Umrandung und Rand etwas der unbestickte Stoff zu sehen ist. Das kommt daher das der Orginalstoff weicher ist als der den ich für die Tests verwendet habe. In der Sticksoftware gäbe dafür einen Korrektionsparamater, der die Stiche dann ein paar Prozente größer macht.

mehr...

Wenger Online#Blog

03.02.2013 20:26:25

Näharbeiten

unsere Kleinen brauchten neue Mützen für Schnee, gewünscht war was “Drachiges”. Durch den verlängerten Halsteil bleibt es auch bei eisigem Wind schön warm an den Ohren. Wenn gewünsch kann ich gerne ein Schnittmuster hochladen. Passende Handschuhe mit Drachenzacken gabs auch noch dazu.

Mütze-Gelb Mütze-Blau
mehr...

nomeata’s mind shares

31.01.2013 20:03:00

Going to FOSDEM after all

Earlier this week, things were looking different, and I did have to cancel a Haskell talk in Freiburg on Monday due to illness. But I’m back on track and will be travelling to Brussels tomorrow.

I’ll be holding a talk on how we package Haskell in Debian, on Suday at 15:30. I hope it will be useful to Debian users (who will better understand the packaging), other Debian Developers (who’ll learn about the peculiarities of Haskell and the implications for the Debian infrastructure), other distro’s maintainers (to compare best practices) and Haskell developers (to learn about the needs and worries of downstream packages). The talk will be based on my DebConf 11 talk on the same topic. I’m also happy to answer questions about Haskell, Haskell in Debian or any other topic that you want to hear my opinion about, so just talk to me during FOSDEM.

In related news: GHC 7.6.2 was uploaded to Debian experimental the day it was released; the rebuilding of all libraries is still in progress (~370 of ~570 done).

mehr...

Hanno's blog

26.01.2013 10:51:00

Explain hard stuff with the 1000 most common words #UPGOERFIVE

Based on the XKCD comic "Up Goer Five", someone made a nice little tool: An online text editor that lets you only use the 1000 most common words in English. And ask you to explain a hard idea with it.

Nice idea. I gave it a try. The most obvious example to use was my diploma thesis (on RSA-PSS and provable security), where I always had a hard time to explain to anyone what it was all about.

Well, obviously math, proof, algorithm, encryption etc. all are forbidden, but I had a hard time with the fact that even words like "message" (or anything equivalent) don't seem to be in the top 1000.

Here we go:

When you talk to a friend, she or he knows you are the person in question. But when you do this a friend far away through computers, you can not be sure.
That's why computers have ways to let you know if the person you are talking to is really the right person.

The ways we use today have one problem: We are not sure that they work. It may be that a bad person knows a way to be able to tell you that he is in fact your friend. We do not think that there are such ways for bad persons, but we are not completely sure.

This is why some people try to find ways that are better. Where we can be sure that no bad person is able to tell you that he is your friend. With the known ways today this is not completely possible. But it is possible in parts.

I have looked at those better ways. And I have worked on bringing these better ways to your computer.


So - do you now have an idea what I was taking about?

I found this nice tool through Ben Goldacre, who tried to explain randomized trials, blinding, systematic review and publication bias - go there and read it. Knowing what publication bias and systematic reviews are is much more important for you than knowing what RSA-PSS is. You can leave cryptography to the experts, but you should care about your health. And for the record, I recently tried myself to explain publication bias (german only).
mehr...

Hanno's blog

19.01.2013 10:45:00

How to configure your HTTPS server

Yesterday, we had a meeting at CAcert Berlin where I had a little talk about how to almost-perfectly configure your HTTPS server. Motivation for that was the very nice Qualys SSL Server test, which can remote-check your SSL configuration and tell you a bunch of things about it.

While playing with that, I created a test setup which passes with 100 points in the Qualys test. However, you will hardly be able to access that page, which is mainly due to it's exclusive support for TLS 1.2. All major browsers fail. Someone from the audience told me that the iPhone browser was successfully able to access the page. To safe the reputation of free software, someone else found out that the Midori browser is also capable of accessing it. I've described what I did there on the page itself and you may also read it here via http.

Here are my slides "SSL, X.509, HTTPS - How to configure your HTTPS server" as ODP, as PDF and on Slideshare.

And some links mentioned in the slides:
Check SSL and SSH weak keys due to broken random numbers
EFF SSL Observatory
Sovereign Keys proect

Some great talks on the mentioned topics by others:
Facthacks Talk 29c3
MD5 considered harmful today - Creating a rogue CA Certificate
Is the SSLiverse a safe place?

Update: As people seem to find these browser issue interesting: It's been pointed out that the iPad Browser also works. Opera with TLS 1.2 enabled seems to work for some people, but not for me (maybe Windows-only). luakit and epiphany also work, but they don't check certificates at all, so that kind of doesn't count.
mehr...

nomeata’s mind shares

10.01.2013 22:24:00

“Haskell Bytes” again

Janis Voigtländer has invited me again to give a lecture in his Advanced Functional Programming course at the University of Bonn. Like last time, when I talked about performance analysis in Haskell, I chose a topic that is more on implementationishy side to contrast the theoretic content of the rest of the course. I recycled my talk on the memory representation of GHC that I have held at last year’s Meta Main-Rhein Chaos Days. As usual I provide a transcript of the talk as intended (not as held). It is slightly revised over the old version and I have added a section on unboxed values in constructors, which I have nevertheless skipped today.

mehr...

nomeata’s mind shares

05.01.2013 19:55:00

Brief an den KVV

Schlagzeile auf kvv.de: KVV führt probeweise ganztägigen kontrollierten Busverkehr in Karlsruhe ein. Das gefällt mir nicht, daher hab ich folgenden „Brief“ dem KVV über deren Kontakt-Formular zukommen lassen. Vielleicht hilft es ja was.

Sehr geehrter KVV,
vor meiner Zeit in Karlsruhe lebte ich im Bereich des VVS; seit 8 Jahren jetzt in Karlsruhe. Ich habe mich, gerade im Vergleich, stets darüber gefreut, in Karsruhe auch hinten in den Bus einsteigen zu dürfen. Aus mehreren Gründen macht es mir die Teilnahme am ÖPNV attraktiver:

  • Es geht schneller. Gerade wenn man sich um Anschlüsse sorgen machen muss schont es die Nerven doch sehr wenn sich nicht an jeder Haltestelle alle neuen Fahrgäste erst eine Schlange bilden und einzeln am Fahrer vorbeitrotten, nachdem sie ihre Karte hervorgeholt haben.
  • Ich muss meine Dauerkarte nicht dauernd griffbereit haben. Es genügt, sie bei Bedarf, also bei einer Kontrolle, herauszukramen.
  • Ich fühle mich wohler wenn mir als Fahrgast ein Grundvertrauen entgegen gebracht wird, nämlich dass erst einmal davon ausgegangen wird dass ich ein ehrlicher Fahrgast bin. Die stichprobenhaften Kontrollen sind mir dann natürlich willkommen. Wird dagegen bei jeder Busfahrt erstmal angenommen, dass ich ein Schwarzfahrer bin, bis ich dem kritisch-prüfenden Blick des Fahrers das Gegenteil bewiesen habe, kann davon nicht mehr die Rede sein.

Ich hoffe daher sehr dass der „kontrollierte Fronteinstieg“ im KVV nur ein kurzer Test bleibt und ab April wieder eingestellt wird.

Vielen Dank,
Joachim Breitner

mehr...

The Turkey Curse

03.01.2013 11:58:00

Entschuldigt bitte, Flauscheria!

An Tag 3 des 29C3 bin ich ausgeflippt und habe Euch heftig angeschrien. Anlass für diesen Ausbruch war, dass ich erstmals den Text auf den roten Creeper Cards gelesen hatte (die ich als Idee bekanntermaßen schon vorher schwierig fand) - und das leider direkt nach dem Aufstehen, mit wenig Schlaf, ohne Kaffee oder Frühstück, nach irrsinnig arbeitsreichen und weihnachtsfreien Wochen, stressigen Tagen und einigen Geschichten, die sich auf der Veranstaltung hochgeschaukelt haben. Die Androhung von Gewalt auf diesen Karten hat mich in dem Moment unverhältnismäßig wütend gemacht und die Situation ist heftig eskaliert. Auf die genauen Hintergründe und die Vorgeschichte gehe ich vielleicht noch an gesonderter Stelle ein.

Aber vollkommen egal, was da im Vorfeld abgelaufen sein mag und wo die sachlichen und emotionalen Hintergründe meines Verhaltens lagen: Ich habe mich sowohl im Ton als auch in der Lautstärke und Form erheblich vergriffen. Das geht so nicht, und ich möchte bei Euch in aller Form um Entschuldigung bitten. Ich bereue diesen Ausbruch sehr, es tut mir wirklich leid.

fukami

mehr...

nomeata’s mind shares

20.12.2012 13:09:00

GHCi integration for GHC.HeapView

Given the very positive feedback for Dennis Felsing’s tool ghc-vis, which visualizes the heap representation of a Haskell value, including all the gory details such as thunks, values retained by thunks indirections, sharing etc, I saw the need to provide this information also directly in GHCi, without having to load a graphics library or opening extra libraries. So I added the required features (traversing the heap and pretty-printing the results) to my ghc-heap-view package and, also following ghc-vis’s lead, added a ghci file that, when loaded, provides you with a :printHeap command. Here you can see it in action:

A plain value

Prelude> :script /home/jojo/.cabal/share/ghc-heap-view-0.4.0.0/ghci
Prelude> let x = [1..10]
Prelude> x
[1,2,3,4,5,6,7,8,9,10]
Prelude> :printHeap x
_bh [S# 1,S# 2,S# 3,S# 4,S# 5,S# 6,S# 7,S# 8,S# 9,S# 10]

Note that the tools shows us that the list is a list of S# constructors, and also that it is still hidden behind a blackhole. After running System.Mem.performGC, this disappears.

A thunk

Prelude> let x = Just (1 + 1)
Prelude> :printHeap x
Just _bco
Prelude> x
Just 2
Prelude> System.Mem.performGC
Prelude> :printHeap x
Just (S# 2)

Here, we see how the calculation was deferred until forced by showing the value of x. The name _bco stands for a bytecode object as used by the interpreter. Getting useful information from them is a bit harder than for compiled thunks, so for more accurate results put the code in a Haskell source file, compile it and use the GHC.HeapView API to print the interesting parts.

A partial application

Prelude> let a = "hi"
Prelude> let partial = (a ++)
Prelude> partial ""
"hi"
Prelude> System.Mem.performGC
Prelude> let x = (a, partial)
Prelude> :printHeap x
let x1 = "hi"
in (x1,_fun x1)

The information which function is called there (++ in this case) is lost at runtime, but we still see that the second element of the tuple is a partial application of some value to the first element.

A cyclic structure

Prelude> let s = "ho"
Prelude> let x = cycle s
Prelude> length (take 100 (show x))
100
Prelude> System.Mem.performGC
Prelude> :printHeap x
let x0 = C# 'h' : C# 'o' : x0
in x0
Prelude> let y = map Data.Char.toUpper x
Prelude> length (take 100 (show y))
100
Prelude> :printHeap y
C# 'H' : C# 'O' : C# 'H' : C# 'O' : C# 'H' : C# 'O' : C# 'H' : C# 'O' : C# 'H' : C# 'O' : _bh (C# 'H' : C# 'O' : C# 'H' : C# 'O' : C# 'H' : C# 'O' : C# 'H' : C# 'O' : ... : ...)

The cyclic, tying-the-knot structure of cycle is very visible. But can also see how easily it is broken, in this case by mapping a function over the list.

Mutual recursion

Prelude> let {x = 'H' : y ; y = 'o' : x }
Prelude> length (show (take 10 x, take 10 y)) `seq` return ()
Prelude> System.Mem.performGC
Prelude> :printHeap (x,y)
let x1 = C# 'H' : x3
    x3 = C# 'o' : x1
in (x1,x3)

If you want to look at multiple variables at once, just pass a tuple to printHeap

In the hope that this will be a useful tool for you, I uploaded version 0.4.0.0 of ghc-heap-view to hackage.

mehr...

nomeata’s mind shares

16.12.2012 18:04:00

Circle Packing

For an upcoming introductory Haskell talk of mine (next Tuesday in Karlsruhe – please come and join if you will) I was looking into data visualization as a example application. With libraries like gloss, getting some nice vector graphics up and running within one talk is quite possible.

For some reason, I want to arrange multiple circles of varying size so that they do not overlap and use as little space as possible. My first approach was to use general purpose optimizers such as cmaes, Numeric.GSL.Minimization from the hmatrix package and force-layout. I especially liked the interface of cmaes, which is able to minimize a function of, say, type [(String, Double, Double)] -> Double by automatically finding the values of type Double in the input, as described by Takayuki Muranushi. That would have looked great in the talk. Unfortunately, none of these libraries gave sufficient good results in a reasonable amount of time for this problem.

I then reviewed some of the academic literature on the circle packing problem and there were some algorithms proposed, but no simple one and none of the papers had a concise pseudo-code description that I could transfer to Haskell.

So eventually I set out to implement a relatively dump and slow greedy algorithm myself: I place one circle after another, starting with the largest, and among the valid positions where a new circle touches two already placed circles, I choose the positions closest to the center of mass. The result, available in the circle-packing package, looks surprisingly well, here visualized using the diagrams library (See the documentation of Optimisation.CirclePacking for the code used to generate that image):

Now showing just this image is not a very good way to demonstrate my code. A few years ago, I might have created a CGI script that would dynamically generate images based on your input. But not in 2012: Since my code is pure Haskell without fancy features like type classes, I can use the fay compiler to generate JavaScript code from it. Add a little Haskell code to interact with the HTML5 canvas and now you can interactively try out circle-packing in your browser.

Oh, and while I am talking about neat tricks: You can put vector graphics in your haddock documentation, as I have done for Optimisation.CirclePacking, using the syntax <<<data:image/svg+xml;base64,PD94bWwgdmV...c3ZnPg==>>.

mehr...

nomeata’s mind shares

14.12.2012 18:07:00

Plätzchentetris

What happens if the same person (in this case, my girlfriend) is both a bit geeky and likes to bake? She has ideas leading to this:

Tetris Biscuits

And what is the obvious thing to do with such biscuit (or are they cookies?). Play tetris:

(Also on YouTube if your browser does not play the video above.)

Oh, and to refute common stereotypes about me: The baking was done by me, but she helped me glazing the biscuits.

mehr...

nomeata’s mind shares

07.12.2012 22:22:00

Calculating the internal rate of return with hledger

For more than ten years now, I am a regular and happy user of GnuCash, the free accountancy program. Especially the integrated online banking support for HBCI that allows me not only to fetch my transactions, but also to transfer money using a cryptographic makes it a great tool. Nevertheless, it has shortcomings, especially when it comes to reports. And for some reason I never felt the urge to hack on that C/Guile code (although I recently hacked a bit on the UI).

Joey Hess’ blog post about Simon Michael’s hledger made me look at that command line based accountancy tool. It certainly won’t replace Gnucash for me, but luckily ledger, of which hledger is a re-implementation, can read GnuCash’s file format and convert it to a ledger file that hledger can read as well. So now I can do analysis on my financial data in Haskell – what would you want more?

One report that I was missing was the internal rate of investment of some account. This is the annual rate of a hypothetical fixed interest-bearing savings account that would, given the same deposits and payouts, result in the same final value. I now implemented this as the hledger-irr command and – as you would expect – you can find it on hackage. See the package description for documentation and example output.

It is very fresh, hardly tested code, so don’t base important decisions on it yet. Also, it needs work to work correctly with multiple currencies or things with varying prices, and I am not yet sure what to do there.

Update: Simon asked me to elaborate the difference to hledger-interest by Peter Simons (on which my code was initial based, but eventually I rewrote everything but the option parsing code). The difference is that hledger-interest answers the question „I have this investment with this yearly interest rate (which may even change), how large are the interest payments going to be.“ I imagine a usecase is that you have borrowed some money to a friend at a certain (surely amicable) rate and need to figure out what he owes you, even when you gave him the money mid year and he payed you some back shortly after easter. hledger-irr serves a different purpose: Here you already know your investment payments, gains and losses and you want to have a number describing “how good” your investment was. One usecase might be that, at the end of a live of paying into a pension fund, you ask yourself: “Given all the feeds and commissions, was this a good idea or should I just have invested the money myself?” Then the internal rate of investment tells you how lucrative an alternative fixed-rate investment would have had to been to match your pension fund investment. (Or course this is not the only aspect that you should look at when comparing investments, as it totally ignores risk and possible insurance elements of the investment.)

mehr...

experimentalworks

05.12.2012 00:12:39

Probing PHP with Systemtap on Linux

DTrace is a dynamic tracing tool build by Sun Microsystems and is available for Solaris, MacOS and FreeBSD. It features a tracing language which can be used to probe certain “probing” points in kernel or userland. This can be very useful to gather statistics, etc. Linux comes with a separate solution called systemtap. It also features a tracing language and can probe both userland and kernel space. A few Linux distributions such as Fedora enable systemtap in their default kernel.

PHP introduced DTrace support with PHP 5.3, enabling probing points in the PHP executable that can be used to simplify probing of PHP applications without having to the PHP implementation details. We enabled probes on function calls, file compilation, exceptions and errors. But this has always been limited to the operating systems that support DTrace. With the popularity of DTrace, Systemap programmers decided to add a DTrace compatibility layer that allows to use DTrace probes as Systemtap probing points as well.

With my recent commit to the PHP 5.5 branch, we allow DTrace probes to be build on Linux, so people can use Systemtap to probe those userland probes.

To compile PHP with userland probes you need to obtain the PHP 5.5 from git:

$ git clone git://github.com/php/php-src php-src
$ cd php-src
$ git checkout PHP-5.5
Now build PHP with DTrace support. First we have to rebuild configure as we build directly from the repository. Make sure your Linux distribution comes with systemtap and uprobes support.

$ ./buildconf --force
$ ./configure --disable-all --enable-dtrace
$ make
After being done with building we can see if we found any probes:

$ stap -l 'process.provider("php").mark("*")' -c 'sapi/cli/php -i'
process("sapi/cli/php").provider("php").mark("compile__file__entry")
process("sapi/cli/php").provider("php").mark("compile__file__return")
process("sapi/cli/php").provider("php").mark("error")
process("sapi/cli/php").provider("php").mark("exception__caught")
process("sapi/cli/php").provider("php").mark("exception__thrown")
process("sapi/cli/php").provider("php").mark("execute__entry")
process("sapi/cli/php").provider("php").mark("execute__return")
process("sapi/cli/php").provider("php").mark("function__entry")
process("sapi/cli/php").provider("php").mark("function__return")
process("sapi/cli/php").provider("php").mark("request__shutdown")
process("sapi/cli/php").provider("php").mark("request__startup")
Let’s build us a short Systemtap script that counts the function calls of a specific function. we use the function-return and function-entry probes for that:

$ cat request.stp
global callcount;
probe process.provider("php").mark("function-entry") {
    callcount[user_string($arg1)] += 1;
}
probe end {
    printf("count : function\n");
    foreach (name in callcount) {
        printf("%5d : %s\n", callcount[name], name);
    }
}
$ sudo stap -c 'sapi/cli/php test.php' request.stp
count : function
  100 : foo
  101 : bar

So that’s all. You can use systemtap now to probe your PHP. Hope you come up with some useful scripts. Share them!

flattr this!

mehr...

nomeata’s mind shares

24.11.2012 19:35:00

screen-message is now scriptable more easily

Motivated by a user’s mail, I worked a little bit on screen-message aka sm.This tool, which I wrote 6 years ago and is in Debian since 2007, displays a (possibly multi-line) text as large as possible on your screen and can be used in many, mostly spontaneous ways.

It has always been used in a scripted setting as well, e.g. as make-shift slides for a lightning talk. This is now possible without having to quit sm (and hence flickering): Since version 0.20, you can continuously feed text to "sm -" and it will display everything until the next form feed character (or the end of the file). So this command produces a make-shift digital wall clock, if you happen to need one:

       (while sleep 1; do date +%T; echo -e '\f'; done) | sm -

Since Debian is currently in a freeze to eventually release wheezy (and this feature is hardly release critical) you will have to fetch the new version from experimental.

By the way, screen message is also available as a web version on http://sm.nomeata.de/  and as a Mozilla WebApp (although the usability on smart phone can still be improved, considering that I do not own such a device).

mehr...

Hanno's blog

16.11.2012 11:47:00

Brief an die Naturstrom AG

In Deutschland gibt es vier Stromanbieter, die man üblicherweise empfielt, wenn man nach einem vertrauenswürdigen Ökostromanbieter fragt. Lichtblick, Greenpeace Energy, die Naturstrom AG und die Elektrizitätswerke Schönau. Die taz hat nun eine spannende Geschichte: Drei der vier beziehen Strom von einem österreichischen Unternehmen, welches gerade in der Türkei ein Braunkohlekraftwerk baut.

Nun bin ich Kunde bei dem vierten Anbieter, der davon nicht betroffen ist - und den ich somit auch bedenkenlos weiterempfehlen kann: Die Elektrizitätswerke Schönau. Allerdings beziehe ich mein Gas von der Naturstrom AG. Diese haben nämlich auch einen Biogas-Tarif im Angebot (und sind - wie ich das in der Vergangenheit wahrgenommen habe - durchaus bemüht, dabei nicht Massentierhaltung und Maismonokulturen zu unterstützen).

Anlass genug für mich, dort mal nachzufragen. Wer seinem Anbieter ebenfalls schreiben will, darf das natürlich gerne als Vorlage verwenden (und ich bitte die teilweise etwas flapsigen Formulierungen zu entschuldigen - ich hatte ursprünglich nicht vor das zu veröffentlichen, bin aber gerade darum gebeten worden):

Sehr geehrte Damen und Herren,

Ich habe gestern diesen Artikel in der taz gelesen:
http://www.taz.de/Alternative-Stromlieferer/!105629/

Nun beziehe ich zwar von der Naturstrom AG keinen Strom, sondern nur Gas, aber trotzdem bewegt mich das Thema. Ich habe die Naturstrom AG bisher immer als vertrauenswürdig erlebt und als Unternehmen, das "Öko" nicht nur als Werbegimmick nutzt wie viele andere, sondern ernst nimmt.

Nun interessiert mich natürlich zum einen, wie die Naturstrom AG auf diese Enthüllungen reagieren will. Zum anderen interessiert mich aber auch, wie das überhaupt passieren konnte. Wenn ich mal ihre Webseite zitieren darf - dort steht: "Natürlich achten wir auch darauf, dass keine Atom- und Kohlekonzerne an den Erzeugungsanlagen beteiligt sind."

Es würde mich ja interessieren, wie das konkret aussieht. Denn eigentlich würde ich ja davon ausgehen, dass sie das nicht nur so sagen, sondern auch - bei Verhandlungen - in den Lieferverträgen festklopfen. Auch wäre es ja eigentlich wünschenswert, dass ein Ökostromunternehmen nicht nur Strom von Partnerunternehmen bezieht, sondern dort solche Entscheidungen beeinflusst, bevor sie getroffen werden. Der Bau des Braunkohlekraftwerks wird sich nun wohl - selbst wenn ihr Unternehmen und die beiden anderen betroffenen Ökostromer jetzt ihre Verbindungen mit der Verbund AG kappen - nicht mehr verhindern lassen.

Ich bin schon in gewisser Weise enttäuscht, dass so etwas passieren konnte. Von ihrer Antwort werde ich es sicher auch abhängig machen, ob ich weiter bei Ihnen mein Biogas beziehen möchte oder mir auch hier einen anderen Anbieter suche. Natürlich werde ich auch davon abhängig machen, ob ich sie künftig noch bedenkenlos an andere Menschen weiterempfehlen kann.

Mit freundlichen Grüßen, Hanno Böck


Update: Ich hab recht schnell eine Antwort bekommen:

Sie können uns glauben, dass wir uns sehr über die Kohlekraftwerkspläne der Verbund AG ärgern. Zu Ihren Fragen kann ich Ihnen folgende Auskunft geben:

naturstrom sieht die Beteiligung der Verbund AG an dem voraussichtlich 2015 in Betrieb gehenden Braunkohlekraftwerk Tufanbeyli äußerst kritisch und distanziert sich ausdrücklich von diesen Plänen. Daher hat naturstrom die Initiative für ein gemeinsames Vorgehen der betroffenen Ökostromanbieter gegenüber der Verbund AG übernommen. Unser Ziel ist, die Verbund AG von ihrem Vorhaben abzubringen und zum Verkauf der Projektbeteiligung zu bewegen. Ein Schreiben diesen Inhalts an die Verbund AG ist derzeit in Abstimmung. Darüber hinaus werden Gespräche mit Robin Wood sowie mit der Initiative "Atomausstieg selber machen" stattfinden, um die Situation zu besprechen und Lösungswege zu erarbeiten. Wie Robin Wood in ihrer eigenen Stellungnahme geschrieben hat, gelten im Stromgroßhandel Verträge über mehrere Jahre. Daher ist es unser Ansatz, die Verbund AG von der Aufgabe des Vorhabens zu überzeugen, bevor das Kraftwerk in ca. drei Jahren fertiggestellt wird.


Das liest sich für mich erstmal zumindest so, dass man das Problem ernst nimmt. Auf der Homepage von Greenpeace Energy gibt es inzwischen eine Stellungnahme, die allerdings eher wachsweich klingt. Bei Naturstrom und Lichtblick steht bisher nicht, was ich ein bißchen schwach finde.

Update 2: Da mich immer noch Leute auf diesen Blogbeitrag ansprechen: Inzwischen hat die Verbund AG sich von ihren Anteilen an dem türkischen Braunkohlekraftwerk getrennt. Die gehören jetzt E.ON (wer dort Kunde ist, sollte das eh schleunigst ändern - aber dafür braucht's als Grund kein weiteres Braunkohlekraftwerk). Ich wollte mit dem Blogeintrag auch nicht sagen, dass ich die genannten Ökostromer nicht mehr weiterempfehlen kann. Ich denke nach wie vor, dass Naturstrom, Greenpeace Energy und Lichtblick an vielen Stellen gute Arbeit machen.
mehr...

Hanno's blog

09.11.2012 21:53:00

Languages and translation technology

Chinese timetableJust recently, Microsoft research has made some progress in developing a device to do live translations from English into Mandarin. I'd like to share some thoughts with you about that.

If you read my blog on a regular basis, you will know that I traveled through Russia, Mongolia and China last year. If there's one big thing I learned on this trip, it's this: English language is - on a worldwide scale - much less prevalent than I thought. Call me a fool, but I just wasn't aware of that. I thought, okay, maybe many people won't understand English, but at least I'll always be able to find someone nearby who's able to translate. That just wasn't the case. I spent days in cities where I met nobody that shared any language knowledge with me.

I'm pretty sure that translation technologies will become really important in the not-so-distant future. For many people, they already are. I've learned about the opinions of swedish initiatives without any knowledge of swedish just by using Google translate. Google Chrome and the free variant Chromium show directly the option to send something through Google translate if it detects that it's not in your language (although that wasn't working with Mongolian when I was there last year). I was in hotels where the staff pointed me to their PC with an instance of Yandex translate or Baidu translate where I should type in my questions in English (Yandex is something like the russian Google, Baidu is something like the chinese Google). Despite all the shortcomings of today's translation services, people use them to circumvent language barriers.

Young people in those countries are often learning English today, but it's a matter of fact that this will only very slowly translate into a real change. Lots of barriers exist. Many countries have their own language and another language that's used as the "international communication language" that's not English. For example, you'll probably get along pretty well in most post-soviet countries with Russian, no matter if the countries have their own native language or not. This also happens in single countries with more than one language. People have their native language and learn the countries language as their first foreign language.
Some people think their language is especially important and this stops the adoption of English (France is especially known for that). Some people have the strange idea that supporting English language knowledge is equivalent to supporting US politics and therefore oppose it.

Yes, one can try to learn more languages (I'm trying it with Mandarin myself and if I'll ever feel I can try a fourth language it'll probably be Russian), but if you look on the world scale, it's a loosing battle. To get along worldwide, you'd probably have to learn at least five languages. If you are fluent in English, Mandarin, Russian, Arabic and Spanish, you're probably quite good, but I doubt there are many people on this planet able to do that. If you're one of them, you have my deepest respect (please leave a comment if you are).

If you'd pick two completely random people of the world population, it's quite likely that they don't share a common language.

I see no reason in principle why technology can't solve that. We're probably far away from a StarTrek-alike universal translator and sadly evolution hasn't brought us the Babelfish yet, but I'm pretty confident that we will see rapid improvements in this area and that will change a lot. This may sound somewhat pathetic, but I think this could be a crucial issue in fixing some of the big problems of our world - hate, racism, war. It's just plain simple: If you have friends in China, you're less likely to think that "the chinese people are bad" (I'm using this example because I feel this thought is especially prevalent amongst the left-alternative people who would never admit any racist thoughts - but that's probably a topic for a blog entry on its own). If you have friends in Iran, you're less likely to support your country fighting a war against Iran. But having friends requires being able to communicate with them. Being able to have friends without the necessity of a common language is a fascinating thought to me.
mehr...

nomeata’s mind shares

05.11.2012 18:39:00

Somewhere in Israel, someone printed 50 copies

Today, a small package was waiting for me at my door step, containing 52 printed and stapled copies of a paper that I wrote a while ago. To be more precise, two years ago, when I submitted the main results of my math Diploma Thesis to the Israel Journal of Mathematics. Next year at christmas eve, it was accepted and published online. And now, it seems, it finally went into print. So my paper now has page numbers and I have this pile of printouts that outnumbers the set of possibly interested readers by four dozens or more, and they would probably just download the online version instead of asking for this print out. This seems all very anachronistic to me.

mehr...

Wenger Online#Blog

04.11.2012 17:26:26

Ferien auf Pianta Monda

Nachdem wir schon etwas länger die Novita (die Vereinszeitschrift von Pianta Monda) mitlesen, haben wir es in den Herbstferien endlich geschafft einmal wieder ins Tessin zu fahren. Die Hinfahrt verlief ohne größere Staus und so sind wir am späten Nachmittag in Menzonio angekommen. Hier mussten wir all unser Gepäck auf die Schultern nehmen und erstmal einen ziemlich steilen Berg hinaufsteigen. Es gieng mindestens 15min. sehr steil Bergauf und wir waren uns nie ganz sicher ob wir uns auch auf dem richtigen Weg befanden, doch dann war Pianta Monda in Sicht. Ulrico hieß uns Willkommen und Peter zeigte uns unsere Behausung. Wir waren gerade die einzigen Gäste und so hatten wir das ganze Gästehaus für uns aleine.

P1040141 P1040139 P1040143 Sonnenaufgang panorama P1040132-P1040134 panorama P1040266-P1040276 panorama P1040293-P1040298
mehr...

nomeata’s mind shares

24.10.2012 18:49:00

c't features Haskell

This week’s issue of c't, one of Germany’s largest and most influential computer magazine, has a six page introductory article about Haskell (c't 2012, Issue 23, pages 182-187). The author Harad Bögeholz demonstrates its features and strength by implementing a Slitherlink puzzle solver. As I have helped him a bit by checking the code and article for untypical Haskell code and general advice, I happen to be named at the end of the article – nice.

mehr...

Hanno's blog

17.10.2012 09:00:00

Das Ärgernis GEMA

GEMA-Sperre auf YoutubeÜber die GEMA könnte man viel schreiben und sich viel ärgern, etwa jedes zweite mal, wenn man auf ein Youtube-Video klickt und erzählt bekommt, dass dieses Video "in Deinem Land nicht verfügbar" ist. Ein besonders krasses Ärgernis ist aber die sogenannte GEMA-Vermutung. Sie bewirkt letztendlich, dass die GEMA Geld für Musiker kassieren kann, die überhaupt nicht bei ihr Mitglied sind.

Wie funktioniert das? Grob gesagt sagt die GEMA-Vermutung folgendes: Man geht davon aus, dass fast alle Musik von der GEMA vertreten wird und somit im Zweifel immer angenommen wird, dass die GEMA Ansprüche auf Zahlungen hat. Konkret: Wer ein Konzert ausrichten, eine CD produzieren oder sonst etwas mit Musik machen will, muss damit rechnen, von der GEMA behelligt zu werden - und zwar auch dann, wenn die betroffenen Künstler nicht bei der GEMA Mitglied sind. Denn beweisen muss man das selbst. Das führt zu absurden Situationen: Das Landgericht Mannheim forderte etwa, dass alle Musiker, die in der Freiburger KTS über mehrere Jahre aufgetreten sind, als Zeugen persönlich vor Gericht erscheinen sollten. Eine schriftliche Erklärung der Musiker reichte nicht aus. Kürzlich Schlagzeilen machte ein Fall, in dem die Musikpiraten an die GEMA zahlen sollten, weil auf einem von ihnen veröffentlichten Sampler ein Musiker vertreten war, der mit einem Pseudonym auftrat und seinen bürgerlichen Namen nicht nennen wollte. Auch hier bekam die GEMA recht.

Die GEMA-Vermutung ist in der heutigen Zeit völlig absurd. Eingeführt wurde sie, als tatsächlich noch davon ausgegangen werden konnte, dass die Mehrzahl der erfolgreicheren Künstler in ihr Mitlgied waren. Heute gibt es aber zahllose Musiker und Künstler, die andere Wege gehen, die auf Creative Commons-Lizenzen setzen und die mit der GEMA nichts am Hut haben.

Warum schreibe ich das alles? Weil gerade beim Bundestag eine Petition gegen die GEMA-Vermutung läuft - die ihr bitte alle SOFORT unterstützen solltet. Denn sie läuft nur noch bis heute abend und braucht noch gut 10.000 Unterstützer, damit es zu einer Anhörung kommt.
mehr...

nomeata’s mind shares

13.10.2012 13:03:00

Creating a Debian source package without unpacking the source

There may be a situation where you want to create a Debian source package without having to unpack the upstream source. One case is where you store your debian/ directory in a version control system of its own and to build your package, you pass the .dsc file to a tool like pbuilder or some remote builder. Now a modern debian source package is just a text file (the .dsc file) that references two tarballs, one being the upstream source and the other being the Debian directory. Thanks to Niels Thykier on #debian, I found the magic invocation of dpkg-source that allows you to create the .dsc directly from the two tarballs, the control file and the changelog:

> apt-get source --download-only -t experimental haskell-mtl
Reading package lists... Done
Building dependency tree       
Reading state information... Done
NOTICE: 'haskell-mtl' packaging is maintained in the 'Darcs' version control system at:
http://darcs.debian.org/darcs/pkg-haskell/haskell-mtl
Need to get 18.8 kB of source archives.
Get:1 http://http.debian.net/debian/ experimental/main haskell-mtl 2.1.2-1 (dsc) [1616 B]
Get:2 http://http.debian.net/debian/ experimental/main haskell-mtl 2.1.2-1 (tar) [13.7 kB]
Get:3 http://http.debian.net/debian/ experimental/main haskell-mtl 2.1.2-1 (diff) [3509 B]
Fetched 18.8 kB in 0s (22.3 kB/s)    
Download complete and in download only mode
> cp ./haskell-mtl_2.1.2-1.dsc ./haskell-mtl_2.1.2-1.dsc-orig
> tar xzf haskell-mtl_2.1.2-1.debian.tar.gz
> dpkg-source -cdebian/control -ldebian/changelog --format="3.0 (custom)" --target-format="3.0 (quilt)" -b / haskell-mtl_2.1.2.orig.tar.gz haskell-mtl_2.1.2-1.debian.tar.gz
dpkg-source: info: using source format `3.0 (custom)'
dpkg-source: info: building haskell-mtl in haskell-mtl_2.1.2-1.dsc
> diff  -u haskell-mtl_2.1.2-1.dsc haskell-mtl_2.1.2-1.dsc-orig
--- haskell-mtl_2.1.2-1.dsc	2012-10-13 15:09:00.031695856 +0200
+++ haskell-mtl_2.1.2-1.dsc-orig	2012-10-13 15:08:47.267696329 +0200
@@ -1,3 +1,6 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
 Format: 3.0 (quilt)
 Source: haskell-mtl
 Binary: libghc-mtl-dev, libghc-mtl-prof, libghc-mtl-doc
@@ -23,3 +26,11 @@
 Files: 
  943c110524d96126bfa0e61f7df1ebcd 13723 haskell-mtl_2.1.2.orig.tar.gz
  dda5ded58a8d009ecddeed68058ca787 3509 haskell-mtl_2.1.2-1.debian.tar.gz
+
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.12 (GNU/Linux)
+
+iEYEARECAAYFAlBzRQIACgkQ9ijrk0dDIGwymwCfW87jwCv5ZvAXPBwh0LbvYLP9
+n+wAn3TCJwPRuBDEWRYmcv3Opn1Kb9+F
+=/Llc
+-----END PGP SIGNATURE-----

As you can see, the resulting .dsc file is identical to the original one, so this approach works. The parameter to -b does not matter as long as it is some existing directory. Of course you can easily shoot yourself and others in the foot, almost as easily as hand-editing the .dsc file... but if you know what you are doing, then this can be quite handy.

Next to do: Write a tool that takes an unpacked Debian directory as an argument, packs it, finds the original tarball using uscan and creates the .dsc file. Would this be something that people would want in the devscripts package?

mehr...

Hanno's blog

06.10.2012 17:20:00

mycare.de und die Zaubermedizin

Folgende Nachricht habe ich heute an die Onlineapotheke mycare.de geschrieben.

Sehr geehrte Damen und Herren,

Lassen Sie mich kurz etwas vorwegnehmen: Ich habe bereits einige Male bei mycare.de bestellt. Die Preise sind meist günstig und die Lieferungen erfolgten ohne Probleme. Ich teile auch nicht die kulturpessimistische Sorge mancher Zeitgenossen, die Onlineapotheken für schädlich oder gar für den Untergang des Abendlandes halten.

Meiner letzten bei Ihnen bestellten Lieferung lag eine Ausgabe des Magazins “Gesund durch Homöopathie”, herausgegeben von der Deutschen Homöopathie-Union (DHU), bei.

Homöopathie ist keine Medizin – es ist ein Glaubenssystem, das nicht auf wissenschaftlichen Fakten beruht. Homöopathische “Medikamente” bestehen aus Substanzen, die meist so hoch verdünnt sind, dass kein Molekül der Ursprungssubstanz mehr vorhanden ist. Nach den Ideen von Samuel Hahnemann, dem Erfinder der Homöopathie, führt die Verdünnung zu einer Verstärkung des Effekts.

Würde dies tatsächlich stimmen, müssten wir wohl große Teile der Biologie- und auch der Physikbücher umschreiben. So ist es kaum zu erklären, wie sich die Idee der potenzierten Information in Wasserlösungen mit so grundlegenden Dingen wie dem zweiten Hauptsatz der Thermodynamik in Einklang bringen lässt.

Aber – niemand muss die Physikbücher umschreiben, denn alles spricht dafür, dass es sich bei Homöopathie um Pseudomedizin handelt. Zahlreiche Metaanalysen kamen immer wieder zu dem selben Schluss: Bei homöopathischen Medikamenten wirkt lediglich der Placebo-Effekt.

Neben der Tatsache, dass es bei Homöopathie um Zaubermedizin geht, weise ich noch auf folgendes hin: Der Herausgeber der von ihnen verbreiteten Zeitschrift, die Deutschen Homöopathieunion, hatte erst kürzlich einen handfesten Skandal vorzuweisen. Sie finanzierte einen selbsternannten Journalisten, dessen Aufgabe darin bestand, Kritiker der Homöopathie anzuschwärzen. Die Details sind in einem Artikel der Süddeutschen Zeitung beschrieben, auf den ich hier gerne verweise [1].

Aber eigentlich brauche ich Ihnen das nicht zu erzählen. Denn ich gehe davon aus, dass auch bei einer Onlineapotheke Mitarbeiter mit medizinischem Sachverstand angestellt sind. Insofern wissen sie das alles längst, vermutlich besser als ich, der ich lediglich die Kompetenz eines Laien mit Interesse für Wissenschaft vorweisen kann.

Ich weiß nicht, was sie dazu motiviert, derart unwissenschaftliche Propaganda von einer Firma mit fragwürdigen Methoden zu verbreiten. Möglicherweise bekommen sie von der Deutschen Homöopathie-Union dafür Geld, möglicherweise denken sie, dass ihre Kunden derartige “Beigaben” schätzen. Ich halte es für schlicht unverantwortlich. Sie tragen dazu bei, dass unwissenschaftliches Denken gefördert wird. Als Apotheke – auch als Onlineapotheke – haben sie eine Verantwortung. Dazu gehört auch, Patienten keine unsachlichen oder falschen Informationen an die Hand zu geben. Ich werde mir gut überlegen, ob ich in Zukunft noch bei Ihnen einkaufen werde.

Mit freundlichen Grüßen,

Hanno Böck

P.S.: Diese Mail werde ich auf meinem privaten Blog veröffentlichen. Sollten Sie mir hierauf antworten (was ich begrüßen würde), werde ich die Antwort dort ebenfalls veröffentlichen.

[1] http://www.sueddeutsche.de/wissen/homoeopathie-lobby-im-netz-schmutzige-methoden-der-sanften-medizin-1.1397617


In der Hoffnung, dass ich nicht der einzige bin und irgendwann Apotheken damit aufhören, Hokuspokus als Medizin zu verkaufen.

Update: mycare.de hat geantwortet:

Homöopathie ist eine in Deutschland anerkannte alternativmedizinische Behandlungsmethode. So haben Arzt und Patient die Möglichkeit, neben der klassischen Medizin auch die der Homöopathie zu wählen. Viele Kunden von mycare zeigen aufgrund ihrer Bestellungen Interesse an der Homöopathie. Wir möchten dem Wunsch unserer Kunden gerecht werden und informieren daher regelmäßig mit unterschiedlichen Beilagen zu diesem Thema. Eine Beilagensperre können wir für Ihr Konto selbstverständlich einrichten, sofern Sie das wünschen.
mehr...

nomeata’s mind shares

02.10.2012 07:39:00

Dennis Felsing’s thesis on ghc-vis submitted

Last week, my first student ever submitted his bachelor thesis „Visualization of Lazy Evaluation and Sharing“ about a tool he created that allows you to investigate the heap of a running Haskell program, including unevaluated values and their sharing properties, in a visual and interactive manner. You can see it in action at the end of the  video of my lightning talk about ghc-dup at the Haskell Implementors Workshop this year, and read more about it on Dennis’ ghc-vis web page. I’m quite happy about the result and I think I can get used to have other people implement my ideas and needs :-)

Dennis said he is willing to continue the maintenance of the tool, so give it a shot and bombard him with bug reports and feature requests!

mehr...

experimentalworks

02.10.2012 01:59:17

Bookmarks Revisited Part II: Daily Bookmarking

It’s been a long time since I’ve written part I of the bookmarks revisited series. In the last two years, bookmarks changed a lot. They became part Mercurial’s core functionality and a lot of of tools became bookmark aware.

The current state of bookmarks

As of Mercurial 1.8 bookmarks are part of the Mercurials core. You don’t have to activate the extension anymore. Bookmarks are supported by every major Mercurial hosting platform. Commands like hg summary or hd id will display bookmark information. In addition, the push and pull mechanism changed. I will go into details about his Part III of the series.

It’s safe to say, due to it’s exposure, bookmarks became much more mature of the years. It’s time to take a look at how to use them.

Bookmark semantics

Bookmarks are pointers to commits. Think of it as a name for a specific commit. Unlike branches in Mercurial, bookmarks are not recorded in the changeset. They don’t have a history. If you delete them, they will be gone forever.

Bookmarks were initially designed for short living branches. I use them as such. It’s indeed possible to use them in different contexts, but I don’t do that. Please be aware, although they were initially intended to be similar to git branches, they often aren’t. They are not branches, they are bookmarks and they should be used like you would use a bookmark in a book. If you advance to the next site, you move the bookmark (or it gets moved).

A bookmark can be active. Only one bookmark can be active at any time, but it’s okay that no bookmark is active. If you have an active bookmark and you commit a new changeset, the bookmark will be moved to the commit. To set a bookmark active you have to update to the bookmark with hg update <name>. To unset, just update to the current revision with hg update ..

A bookmark can have a diverged markers. Bookmarks that are diverged will have a @NAME suffix. For example test@default. Diverged bookmarks are created during push and pull and will be described in Part III.

A start

I use bookmarks to keep track of short living heads that I use for feature development. One bookmark keeps track of the upstream repository, they rest are my personal markers. Let’s start with creating the initial marker that keeps track of upstream. In this example, I show how I work on Mercurial.

First, we are going to clone the Mercurial repository.

$ hg clone http://selenic.com/hg hg
destination directory: hg
requesting all changes
adding changesets
adding manifests
adding file changes
added 17684 changesets with 34643 changes to 2168 files
updating to branch default
996 files updated, 0 files merged, 0 files removed, 0 files unresolved

The repository is setup to the current tip of the repository. We mark it with the ‘upstream’ bookmark. The star in front of the bookmark shows that it is marked as the current bookmark. Most Mercurial commands try to not be very verbose and only write necessary information to your terminal. It’s okay that creating a new bookmark doesn’t generate any output.

$ hg bookmark upstream
$ hg bookmark
 * upstream                  17683:6d7db5794e8c

To start out with a new feature, we have to make sure to not accidentally advance the master bookmark if we start to commit now. Either deactivate the current bookmark using hg update . or create the new bookmark for the feature we want to use right away. I am going to work on a feature to warn people if they create a bookmark with an ambiguous name. Therefore I call the branch topic/bm-warn-ambiguous.

$ hg bookmark topic/bm-warn-ambiguous
$ hg bookmark
 * topic/bm-warn-ambiguous   17683:6d7db5794e8c
   upstream                  17683:6d7db5794e8c

We can now go ahead and write our feature. I start out with the initial bits and later use the MQ extension to modify the changeset, so my change evolves slowly. After hacking a few minutes on the initial code, we can go ahead and commit it. As topic/bm-warn-ambiguous is marked as the current bookmark it will be moved automatically during commit.

$ vim mercurial/bookmarks.py
$ hg commit -m'bookmarks: warn if bookmark name is ambiguous'
$ hg bookmark
 * topic/bm-warn-ambiguous   17684:d018b3fda542
   upstream                  17683:6d7db5794e8c

Using existing bookmarks

We can use the existing bookmarks and go back to our initial state what we pulled from the main repository. Just use bookmark the same way you use revisions. You can use it together with any command that requires a revision argument.

$ hg update upstream
1 files updated, 0 files merged, 0 files removed, 0 files unresolved
$ hg bookmark
   topic/bm-warn-ambiguous   17684:d018b3fda542
 * upstream                  17683:6d7db5794e8c
$ hg log -r upstream
changeset:   17683:6d7db5794e8c
bookmark:    upstream
parent:      17681:a41fd730f230
parent:      17682:829919ef894a
user:        Matt Mackall 
date:        Sat Sep 29 12:28:52 2012 -0500
summary:     merge with stable

I am not too happy with the name of the bookmark. topic/ seems a way to long prefix. Let’s shorten it and rename the existing bookmark. The hg bookmark -m oldname newname can be used to rename existing bookmarks (-m as in move).

$ hg bookmark -m  topic/bm-warn-ambiguous t/warn-ambiguous
$ hg bookmark
   t/warn-ambiguous          17684:d018b3fda542
 * upstream                  17683:6d7db5794e8c

Bookmarks can be deleted with hg bookmark -d name

$ hg bookmark -d t/warn-ambiguous
$ hg bookmark
 * upstream                  17683:6d7db5794e8c
$ hg bookmark -r 17684 t/warn-ambiguous
$ hg bookmark
   t/warn-ambiguous          17684:d018b3fda542
 * upstream                  17683:6d7db5794e8c

Merging

Suppose we are done with our nice little feature and want to move it into our main development branch which is tracked by upstream. There are a few behaviors that you might be unfamiliar with. Just go ahead and use hg merge bookmark. Obviously, the bookmark cannot be a descendant of the bookmark to merge. Unlike git there is no way to force the merge. Also Mercurial won’t update the bookmark. It will just abort and stay were you are. (For git users: This means, Mercurial doesn’t have the notion of a fast-forward for bookmarks). I am not super happy with this behavior, but it will stay for the moment.

If you have diverged heads and your merge is successful, you can commit the merge. The current bookmark is updated to the new merge commit. The bookmark that was merged stays and doesn’t move. Mercurial always sticks to the rule that only the current bookmark moves.

$ hg bookmark
  t/warn-ambiguous          17684:d018b3fda542
* upstream                  17685:861d6aeee6aa
$ hg merge t/warn-ambiguous
1 files updated, 0 files merged, 0 files removed, 0 files unresolved
(branch merge, don't forget to commit)
$ hg commit -m'Merge'
$ hg bookmark
   t/warn-ambiguous          17684:d018b3fda542
 * upstream                  17686:c6b62c2e15fc

Bookmarks and revsets

Revset is a query language for revisions and files, build into mercurial. hg help revsets will explain the syntax. It’s a very powerful language. If you have the time, learn it. It makes your Mercurial experience that much better and will probably make you complain about endless lines of command line options in other VCS.

The revset language has support for bookmarks. You can use the bookmarks() function to get a set of all revisions that are bookmarked. Use this in combination with the log command to get a detailed list of all bookmarked commits:

$ hg log -r 'bookmark()'
changeset:   17683:6d7db5794e8c
bookmark:    upstream
parent:      17681:a41fd730f230
parent:      17682:829919ef894a
user:        Matt Mackall 
date:        Sat Sep 29 12:28:52 2012 -0500
summary:     merge with stable

changeset:   17684:d018b3fda542
bookmark:    t/warn-ambiguous
tag:         tip
user:        David Soria Parra 
date:        Tue Oct 02 03:07:05 2012 +0200
summary:     bookmarks: warn if bookmake name is ambiguous

More complex queries can be done. If you work with bookmarks on different Mercurial branches you can get a list of all bookmarks of a certain branch with hg log -r ‘branch(stable) and bookmark()’. Have fun playing around. Rewards and cat gifs for posting awesome revset queries the comments.

MQ and bookmarks

So far we have dealt with basic commands. We committed a changeset, we edited a few bookmarks.

Bookmarks were designed to work on short living heads. The usual way to work with slowly evolving, unfinished changesets in Mercurial is MQ (also look at Mercurial phases, a new mechanism to help you with published and drafted commits).

MQ is a stack of queues on top of a Mercurial repository. It’s tightly integrated into Mercurial and uses commits and strip commands to push and pop changes. In my example, I have to continue working on my warn-ambiguous feature. We start by importing the topmost commit into MQ to change the commit. We then edit a new file and use hg qrefresh to update the commit with the new changes.

WARNING: qrefresh will throw away your current bookmark before Mercurial 2.4 (which is not yet released).

$ hg update t/warn-ambiguous
1 files updated, 0 files merged, 0 files removed, 0 files unresolved
$ hg qimport -r tip
$ hg bookmark
 * t/warn-ambiguous          17684:d018b3fda542
   upstream                  17683:6d7db5794e8c
$ vim mercurial/bookmarks
$ hg qrefresh
$ hg bookmark
 * t/warn-ambiguous          17684:a5bbed225a3f
   upstream                  17683:6d7db5794e8c

If we want to create a new commit, we use the command hg qnew name. It will create a new patch on top of the patch stack. We use it to draft the tests for our new commit. If we want to go back to the previous commit that is still on the stack, we use hg qpop to “pop” the topmost patch (the one with the tests) from the stack. If we want to go back we use hg qpush.

Note that the bookmarks will move back if you qpop and forward if you qpush, following your current state on the stack. Instead of hg commit we have to use hg qrefresh (only on of mq’s oddities).

$ hg qnew tests
$ vim tests/test-bookmarks.t
$ hg qrefresh

So most parts of MQ are aware of bookmarks. If finalize the MQ patches with hg qfinish -a our bookmark will just stay. The main issue with that workflow is the lack of support in qrefresh, but this is hopefully going to change with the next release. With that, bookmarks are going to be super useful for developing short living branches.

Naming conventions and alias

It is useful to have some naming conventions for bookmarks. I personally use the prefix t/<name> to denote short living topic branches. I use release/<version> for release branches. Bookmarks without any prefix are used for upstream bookmarks and bookmarks that were automatically pulled from the remote repository.

If you use bookmarks daily, you might want to use setup an alias in your global .hgrc. Just add the entry

[alias]
bm = bookmark

to your ~/.hgrc and test if it works with hg bm.

Conclusion

Bookmarks changed a lot of the last years and most of Mercurials code base is bookmark aware. With the change to qrefresh, it’s going to be good enough for my workflows. Whats your bookmark story? Also Steve Losh wrote an excellent article about the different ways of branching in Mercurial (it has pictures, wwoooo). He also wrote an excellent article about MQ. He wrote a lot of interesting stuff at all, visit his page.

ps: without flattrs, comments or anything like that, there is probably not going to be a part III

flattr this!

mehr...

experimentalworks

01.10.2012 20:04:13

I should…

blog more. Open topics: DTrace Part II, Mercurial Bookmarks Part II.

flattr this!

mehr...

NervengiftLabs

15.08.2012 17:34:00

Humble Bundle for Android #3

Ihr kennt das ja inzwischen: ein Stapel Indiegames für Android, Windows, Linux und Mac, kein DRM, ihr bestimmt den Preis, ein (einstellbarer) Teil davon für einen guten Zweck. Die Spiele könnt ihr dann auch auf Steam freischalten.

Diesmal mit dabei:

mehr...

NervengiftLabs

02.08.2012 15:58:00

AsciiDialog: Fühl dich wie ein Hollywood-Hacker

Mal ein bisschen Eigenwerbung:

In Filmen sind Hacker ja immer voll cool: Tipp tipp tipp tipp – ACCESS GRANTED.

Ich wollte schon immer mal ein Skript bauen, das mir so eine tolle riesige “ACCESS GRANTED”/”ACCESS DENIED” Meldung auf der Konsole ausgibt.

//=====================================================================\\
|  ____ ____ ____ ____ ____ ____    ____ ____ ____ _  _ ___ ____ ___    |
|  |__| |    |    |___ [__  [__     | __ |__/ |__| |\ |  |  |___ |  \   |
|  |  | |___ |___ |___ ___] ___]    |__] |  \ |  | | \|  |  |___ |__/   |
|                                                                       |
\\=====================================================================//

(mein Code-Highlight-Plugin macht die Farben kaputt -.-)

Ich sollte ja eigentlich auf meine Klausuren lernen, aber man kann ja nicht immer nur lernen… Daher habe ich nebenbei diese schon etwas ältere Idee umgesetzt.

Und weil ich ja so viel lernen musste, konnte ich das auch sehr gründlich umsetzen :) Das Ding kann jetzt einen gegebenen Text mit ncurses in einem schönen ASCII-Style Dialog anzeigen, wahlweise auch farbig (rot, blau, grün, weiß) und kann den Text auch vorher durch figlet jagen.

Zu finden ist das Ganze auf GitHub.

Wie funktionierts?

asciidialog foo

Zeigt einen einfachen Dialog mit dem Inhalt foo

asciidialog -f -a "-t -f cyberlarge" foo

Verschönert den Text mit figlet. Zusätzliche Argumente für figlet können mit -a übergeben werden (standardmäßig ist das “-t”, damit figlet die ganze Terminalbreite nutzt).

asciidialog -c red ACCESS DENIED

Mit -c kann man eine Farbe für den Dialog angeben. Möglich sind “red”, “blue”, “green”, “white” and “default” (Terminal Standard benutzen)

 tl;dr

git clone git://github.com/Nervengift/AsciiDialog.git
cd AsciiDialog
./asciidialog.py -f -c red "tl\;dr"
mehr...

Hanno's blog

21.07.2012 19:50:00

And you thought 3D printers are useless

3D-printed replacement partSeveral years ago I bought a kind of very simple wardrobe from IKEA. It's called Bardu and is made out of steel rods and a plastic covering. It stands on wheels.

There are small plastic piece that connects the plastic rods with the wheels. And one of them broke a while back. I went to IKEA and asked for a replacement part. They told me that they don't ship parts for such old items - but they have an offering quite similar to the Bardu that I could buy. Sadly, the design has changed and the wheels are directly connected, so no compatible replacement part. The E-Mail service from IKEA told me the same: No replacement parts for old products.

At this point I could've complained about the fact that we live in a crazy world where someone suggests to you buying a new piece of furniture because a small plastic part of the old one is broken.

I posted a message in the RepRap-forum asking for help. If you don't know the RepRap: It's a 3D-printer, creating objects based on computer models out of simple plastic. The RepRap is an Open Source project built partly out of parts printed on other 3D printers. The idea is: Everyone can (with enough time and passion) built his own RepRap, all the documentation is available online.

I quickly got a response from someone from France who was willing to give it a try and re-create the needed plastic part on his 3D printer. Some message exchange later I sent him the broken and a non-broken part. Today, I got my RepRap-printed replacement part. It fits in perfectly. I'm seriously impressed.

Object on Thingiverse

Update (2012/12/11): I don't want to hide the fact that the whole issue turned out to be much trickier than thought. The original piece broke after a while. DeuxVis was so nice to experiment with likely more stable designs and sent me some more printed parts, but the first one already broke again. You can read the details in the RepRap-forum.
mehr...

Hanno's blog

20.07.2012 10:51:00

Robert Kurz ist tot

Robert KurzDer Kapitalismuskritiker Robert Kurz ist vorgestern im Alter von 68 Jahren gestorben. Seine Texte haben mich maßgeblich politisch geprägt, kaum ein Buch hat mich so fasziniert wie sein Hauptwerk "Schwarzbuch Kapitalismus".

Robert Kurz hat die "Denkschule" der Wertkritik in Deutschland mitbegründet. Er verstand sich immer als Marxist und Kapitalismuskritiker, hat dabei aber nie einen Zweifel daran gelassen, dass er für das, was man heute real existierenden Sozialismus nennt, nichts übrig hatte. Dazu hat er ein eigenes Buch geschrieben, das heute nur noch antiquarisch erhältlich ist ("Der Kollaps der Modernisierung", 1994). "Klassische" linke Kapitalismuskritiker bezeichnete Kurz oft abfällig als "Arbeitermarxisten" oder "Traditionsmarxisten", die positive Bezugnahme auf die Arbeit war für ihn ein zentraler Kritikpunkt (Kurz hat wesentlich das "Manifest gegen die Arbeit" mitgeschrieben).

Kurz ging immer davon aus, dass der Kapitalismus an sich selbst zugrunde gehen wird und auf eine finale Krise zusteuert. Deren Vorboten sah er in der Wirtschaftskrise der letzten Jahre gekommen. Sicher ein guter Grund, sich gerade heute mit seinen Theorien und Texten zu beschäftigen.

Neben dem "Schwarzbuch Kapitalismus" (kostenlose PDF-Version online) gehört sein Aufsatz "Antiökonomie und Antipolitik" zu seinen wichtigsten Texten. Ich hatte den Text einige Zeit später gelesen und er war für mich sowas wie das fehlende Kapitel des Schwarzbuchs, denn er befasst sich mit der Frage, wie es denn - mit Alternativstrukturen zur kapitalistischen Realität - weitergehen könnte. Doch versuche anderer, seine Theorien mit Inhalten zu füllen, führten zu starkem Widerspruch seinerseits ("Robert Kurz ist tot" bei keimform.de).

In jüngeren Jahren hatte man leider den Eindruck, dass sich Kurz vorwiegend am Streit mit der Gruppe Krisis abarbeitete. Von der Gruppierung, die er maßgeblich mitgeprägt hatte, trennte er sich vor einigen Jahren im Streit und gründete die Organisation Exit.
mehr...

Uploads from neingeist

06.07.2012 03:20:31

HAMLET IS DEAD

neingeist posted a photo:

HAMLET IS DEAD

mehr...

Uploads from neingeist

06.07.2012 03:20:30

regenbochenkuchen

neingeist posted a photo:

regenbochenkuchen

mehr...