Monday, April 30, 2007
Geekery & Miscellaneous
Monday, April 30, 2007
Monday, April 30, 2007
Thursday, April 26, 2007
Thursday, April 26, 2007
Tuesday, April 24, 2007
Today’s development platform test was on Mono and IronPython with Gtk#. I was testing the feasibility of achieving three goals:
My current requirement is for several hundred Windows desktops that I’d rather be using a more maintainable operating system on. I’m bound to Windows by third party software that I must support, but don’t want my team’s own work to become a barrier to migration in future.
Mono doesn’t support Windows.Forms very well, so if I am to adopt it, the first task will be to replace WinForms with Gtk# in existing apps. For the evaluation today, I tried the most basic: getting Mono and Gtk# working, and maybe writing a “Hello, World” Gtk# app in Python. My primary environment is a Mac, which made this evaluation more interesting. Could I actually do my development on OS X and deploy on Windows and Linux? The Mono distribution for Mac OS X includes IronPython but not Gtk# (Cocoa# is bundled instead). Gtk# requires the Gtk+ library, which is not a standard component on OS X, and hence Mono’s understandable omission.
Compiling Gtk# involved jumping a few hoops. Basically: symlink the Mono C# compiler /usr/bin/mcs to /usr/local/bin/csc.exe, because Gtk#’s configure script assumes a Microsoft .Net Framework environment, and then edit all Makefiles to set RUNTIME = mono. That compiled it. To install, I had to create gtk-sharp-2.0 under /Library/Frameworks/Mono.framework/Versions/1.2.1/lib/mono and throw in symlinks to all the DLLs from their source location in ../gac.
I then tried this simple Gtk# example in C#:
using Gtk; using System; class Hello { static void Main() { Application.Init (); Window window = new Window ("helloworld"); window.Show(); Application.Run (); } }
But it wouldn’t compile:
$ mcs HelloGtk.cs -pkg:gtk-sharp-2.0 Package gtk-sharp-2.0 was not found in the pkg-config search path. Perhaps you should add the directory containing `gtk-sharp-2.0.pc' to the PKG_CONFIG_PATH environment variable No package 'gtk-sharp-2.0' found error CS8027: Error running pkg-config. Check the above output.
Turned out there were two copies of pkg-config, one from Fink and one from Mono. The solution was to set a common environment variable:
export PKG_CONFIG_PATH=/sw/lib/pkgconfig\ :/usr/lib/pkgconfig\ :/Library/Frameworks/Mono.framework/Versions/1.2.1/lib/pkgconfig
The code compiled but still wouldn’t run:
$ mono HelloGtk.exe Unhandled Exception: System.DllNotFoundException: libgtk-x11-2.0.0.dylib at (wrapper managed-to-native) Gtk.Application:gtk_init (int&,intptr&) at Gtk.Application.Init () [0x00000] at Hello.Main () [0x00000]
Mono couldn’t find the Gtk+ libraries in /sw/lib. Fixing this was uglier; it required messing with the DYLD_LIBRARY_PATH environment variable:
$ export DYLD_LIBRARY_PATH=/sw/lib\ :/Library/Frameworks/Mono.framework/Versions/1.2.1/lib
HelloGtk.exe would run after this, but if I tried anything else, it failed complaining about missing libraries. I couldn’t find a solution. Anyway, I moved on Gtk# from Python, translating the code above line for line. It wouldn’t work. No known module named “Gtk”. Much head-scratching and Googling later, I learnt that IronPython needs a special invocation for .Net assemblies (that’s .Net speak for “libraries”). Here’s the code:
import clr clr.AddReference('gtk-sharp') import Gtk Gtk.Application.Init() window = Gtk.Window("helloworld") window.Show() Gtk.Application.Run()
Kushal has a slightly more elaborate example.
Monday, April 23, 2007
Friday, April 20, 2007
I manage a box with multiple Zope installations. It’s been running low on memory lately, causing one of the older Zope installations to freeze every couple of days. I put together this simple script to monitor Zope’s status, as a standby until a proper solution is found. It’s a simplified version of a script originally written in 2000, when Zope was unstable enough to need it.
#!/bin/sh cd `dirname $0` SCRIPTHOME=`pwd` if (wget http://localhost:8080/ --delete-after -t 1 -T 120 >& /dev/null) ; then # Zope is alive if [ -f $SCRIPTHOME/zope-status.down ] ; then rm -f $SCRIPTHOME/zope-status.down touch $SCRIPTHOME/zope-status.up fi else # Zope is dead if [ -f $SCRIPTHOME/zope-status.up ] ; then rm -f $SCRIPTHOME/zope-status.up touch $SCRIPTHOME/zope-status.down $SCRIPTHOME/zopectl restart fi fi
To use, dump this in your Zope’s bin folder, change the 8080 to whatever port your server is running, set the initial status flag …
$ touch zope-status.up
… and setup a cron job for the user account:
*/5 * * * * ~/zinstance2.7/bin/zopecheck.sh
Wednesday, April 18, 2007
I shot over 500 pictures and need more time to process them. For now, please enjoy this picture of Clio Karabelias playing the harp (another). She appears to have been the most photographed performer of the evening, judging by the number of pictures I’ve seen. There’s a comment or two to be made there on the nature of publicity.
More in a few days.
Wednesday, April 11, 2007
Wednesday, April 11, 2007
The Fireflies Festival of Sacred Music is happening this weekend, from 6PM on Saturday, April 14th, to 6AM the next morning. These pictures are from last year (a report).
The festival is held at Fireflies Ashram, some 30 km south of Bangalore on Kanakapura road. Here’s contact information, a map, and the location in Google Maps. The schedule is up on Wikipedia. Tickets cost about Rs 200 and can be purchased at the venue.
Some of us have been considering using Fireflies as a location for barcampish events over an extended weekend. This will be a good chance to go check out the place.
Monday, April 9, 2007
Monday, April 9, 2007
Sunday, April 8, 2007
Sunday, April 8, 2007
Lest we forget them too soon, ladies and gentlemen, here be the team that made Barcamp 3 possible. Click through for individual names. We of course take no credit for the enthusiasm you brought to the event and made it what it was.
Saturday, April 7, 2007
Last week at Barcamp, during the e-governance session, TB Dinesh of Janastu announced an e-governance conference he was helping organise later in the year, tentatively December 2007.
Typical criticism of e-governance centres around how the digitisation is often an excuse to usher in something else, a something that may not always be in favour of the citizenry in whose name e-governance is justified. The best criticism of the technology itself that I’ve seen is limited to questioning the platforms and vendors used. None of it deals with how the manner of application of the technology, shorn of non-technological motives, correlates with its transformative effect on society.
As Mitch Kapor brilliantly summarised it, in a different context, Architecture is Politics:
When I was first thinking fifteen years ago about the challenge of protecting and fostering freedom and openness on computer networks, I originated the phrase “architecture is politics”. The structure of a network itself, more than the regulations which govern its use, significantly determines what people can and cannot do.
…
When it comes to building a new movement, the converse proposition, “politics is architecture” holds true as well. The architecture (structure and design) of political processes, not their content, is determinative of what can be accomplished. Just as you can’t build a skyscraper out of bamboo, you can’t have a participatory democracy if power is centralized, processes are opaque, and accountability is limited.
BoingBoing has a timeline of Kapor’s thought process.
Dinesh has tentatively titled his conference “Information Architectures for E-Governance”. Here are his notes. Elsewhere on that site, I found another page outlining plans for the event (both links may break). While the site says the event is scheduled to be held in Trivandrum, the plan appears to have changed to Mysore (from personal conversation).
Dinesh has specific questions: what is it that makes computers e-governance, and how can the software backend be strengthened to reduce tampering? The concern: an electronic system may be said to eliminate corruption and redundancies only so far as there is no unauthorised access to the data storage. What was once a social construct defined around persons, economic standing and power hierarchies is now an act of patrolling the technological barriers, in turn defined around a different and (often) unwitting social construct.
In my opinion, a conference of this sort would be incomplete without representation from NIC.
The National Informatics Centre is a government body that provides tech solutions to various other government agencies. By virtue of regulations in India, government agencies can procure from other government agencies without requiring external approval, but must use an open tender process for private suppliers. This makes NIC the primary supplier to much of the government.
NIC built some of the key software components of the e-governance framework in Karnataka, including the Bhoomi land records system, and Rural Digital Services (RDS), a unified interface to services from state departments.
I deal with NIC as part of my work responsibilities and find their motivation structure incomprehensible. It is neither capitalistic nor based on the free software philosophy. If I understand correctly, NIC provides software at no charge, their payment coming out of a central budget. Their units appear to operate independently, for I’ve heard of radically different platform choices in different parts of the country, while each unit more or less sticks to the same platform. The software in Karnataka is not open source. They appear to not be answerable to their client, the government department that takes their software to citizens.
So what, then, motivates them? A concern for the common citizen, an altruistic sense of what’s good for the government department, or an unknown hierarchy within their organisation?
For it has much to do with how the architecture of their software turns into politics and defines what e-governance is in some of India’s most significant projects.
Saturday, April 7, 2007
NRC-FOSS is setting up a network of resource centres across the country. These centres are basically a phone line and email address with one or two persons to respond to queries from the general public, represent the FOSS community at events, and otherwise further the cause of Free and Open Source Software. Resource persons get a stipend. The job is ideally suited for freelancers with spare time and a passion for FOSS.
NRC-FOSS is now seeking to setup a centre in Bangalore and needs resource persons. If you are interested, please contact Kenneth Gonsalves. More information is at the mailing list and the website.
The National Resource Centre for Free and Open Source Software (NRC-FOSS) is a joint initiative of the Government of India with CDAC Chennai and Anna University’s KBC Research Centre, also in Chennai. The two units operate independently. While CDAC has focused on building an Indianised distribution, AU-KBC has built educational materials and the upcoming network of city-specific resource centres.
Friday, April 6, 2007
A long standing issue with this site’s stylesheets has been fixed. IE7 users would see a long horizontal scrollbar, while Firefox users would see the right hand side sections overlapping the dividing line.
This site’s layout is now tested working with Safari 2.0, IE 7.0, IE 6.0, Firefox 2.0 and Firefox 1.0. The font rendering still seems to be a bit of a problem. I use Lucida Grande falling back to Lucida Sans, falling back to Verdana. It appears that some Windows systems have a bitmap version of Lucida that looks horrible. Lucida Grande also lacks an italic face. Safari handles this gracefully by substituting from Lucida Sans. Firefox does not, and as a result, Mac Firefox users get a poor experience.
That, and handheld rendering, remain to be resolved.
Friday, April 6, 2007
On the venue again: suppose we had to settle for the same venue, but got to change how it’s used? We had four rooms across two floors. What if we abandon the upper two, use the lower rooms, and add the space between and the corridors? We could toss some mats around the place and insist that anyone not giving a projected demo get out of the rooms. If someone wants a breakaway discussion, they simply move further down the corridor.
Would that improve camaraderie?
Friday, April 6, 2007
The Barcamp Bangalore wiki needs a facelift. The standard MediaWiki theme doesn’t carry the vibe we want. We’re looking for someone help create a new look for the site, or at least locate a nice theme.
Friday, April 6, 2007
Friday, April 6, 2007
The Barcamp Bangalore 3 planners had a five hour meeting last evening to discuss the outcomes of the last event and plan for the next. We have decided we’re going to aim for three events a year instead of the previously discussed four. The main concern is with logistics: it takes up to a month after the event to settle with sponsors (BCB2 took three), and organising the next needs a month and a half to prepare for venue, suppliers, theme, publicity, and again, sponsors. Our five hour meet yesterday is typical: each meeting runs five to six hours and we need one at least once a week to stay on track.
That leaves us with practically no time to focus on the actual content of the event. Going from four to three events a year gives us that breather, reduces our financial load while buffering for sponsors (lest it was not emphasised enough, the hardest part of organising the event), and most important, from the participants’ perspective, allows us to publish a calendar in advance so everyone can plan their schedules.
BCB4 and BCB5 will be in July and November 2007. The exact dates are subject to venue availability, to be settled soon.
But what about the content? How can organisers be worried about the content when it’s a Barcamp, a supposedly open event where participants decide what the content is?
Reality is somewhat more subtle.
First, as organisers, we have to justify to ourselves why we put in the effort. All of us agree we’re doing this because there is a certain type of outcome we’d like to achieve, the specifics varying from person to person. We’re clear we want to keep the space egalitarian, fair to all participants, with no organiser raising their agenda above the collective’s. And yet, to deny any individual’s motives for facilitating is to remove meaning from the event.
Second, while actual content is defined by participants, there is the greater question of how one decides to become a participant. We recognise that rank strangers will find it difficult to step into a strange new community, so we take the effort to invite them in. Our goal with this is to encourage people from different domains — the kind of people unlikely to visit a Barcamp by themselves — to come in and engage in the discussions. We trust most will appreciate the results.
Third, there is much about the venue that shapes the content. Our venue at IIMB was four classrooms across two floors, with a canteen some distance away. Despite the great ambience and facilities, we had recurring complaints. The classroom environment focused too much attention on the speaker, making it difficult to have interactive discussions. It only worked for presentations. The canteen was a rather drab place; nobody wanted to hang out there. The four rooms had no common meeting point for everyone to mix. We made the rooms available in half hour slots with fifteen minute margins, but several sessions ran over time and then couldn’t continue because someone else had already taken the room for the next slot. We had complaints about no slots being available. It didn’t occur to anyone to take their audience out into the hallway, or to propose a session there.
Somehow the classrooms became the only acceptable place to hold a session. Lawrence’s session was interrupted when the slot time ran out. We announced it would continue over lunch. Some of us pulled two tables together and had a great discussion on intellectual property and piracy. Others milled around wondering when the session was going to happen.
This is a state of expectations we’d rather not have next time. The classrooms were clearly a bad influence. We’ll no doubt have endless debates about how to tweak the environment, but this is what I like most about the current organising team: we’ve learnt to be outspoken for our beliefs and yet arrive at a consensus with everyone agreeing it was best.
I’ll throw in my two paisa here on this blog: I’m unhappy with the slot system. While it’s great for short presentations, it breaks down for longer, focused sessions that run into several hours.
Take Lawrence Liang again. He could have easily presented for three hours, reinforced the point he was making, and then put another two hours into a group discussion so everyone else could clarify their thoughts. Such a session was not possible in BCB3 — despite clear participant interest — because it would run afoul of the organiser’s ethic of not favouring any one participant.
One of my other interest areas is open locative technologies. I’d really like to see a repeat of January’s Freemap Workshop, where Schuyler Erle and Shekhar Krishnan presented for half an hour on what the workshop was about, divided participants into teams, and assigned each team an aspect of the mapping process. The teams then operated independently until the next evening, when they put their efforts together.
I’d like to see a Freemap workshop within Barcamp. It’ll help them get their minds off the logistics and to focus on the content. Having parallel sessions will convince the fence-sitters to dive in on either side. And it’ll help Barcamp improve its overall level of participation and establish it as an event to plan calendars around.
But it does introduce a fundamental question: as organisers with limited venue resources, how do we dedicate a part for the entire period to one group while parcelling out half hour slots to others? If we judge that said group is deserving, does it not violate the sacred line separating organising from content?
Here’s a idea: let groups that want such long term resources propose in advance, on the wiki. Participants vote for the sessions they want to be part of. Based on how many such proposals we get and what is available at the venue, we accommodate as many as possible. We’ll continue to have some rooms dedicated to ad hoc sessions were the schedules are drawn up only each morning.
Makes sense?
Copyright © 1979-2011 by Kiran Jonnalagadda. Licensed under Creative Commons By-NC-SA 2.5. Proudly powered by Zine.