Search Results: "ardo"

10 October 2009

Pablo Lorenzzoni: XMPP4R-Observable now on GemCutter

Just a quick update: XMPP4R-Observable is now on GemCutter. That s due to GitHub disabling gem building, and although everybody can get the source from GitHub as usual, those who want to quickly install it using Rubygems can do:

bash$ gem install xmpp4r-observable -s http://gemcutter.org
Happy Hacking.

28 September 2009

Jon Dowland: Ruby vs. Python

Pablo Lorenzzoni writes to defend Ruby in response to Kanwei Li's April post about dropping it in favour of Python. Kanwei's post has some questionable points that Pablo rightly picks up on (being forced to use ternary operators?) and some that he doesn't ("LOC matters, people."). Just like Kanwei, some time ago I decided to ditch Ruby and focus on Python for the tasks that I would normally use Ruby for. The two final nails in the coffin for me were Interestingly, Pablo cites rubygems as one of the points in favour of Ruby. Whilst both Pablo and Kanwei mostly focus on technical details for their attack and defence of Ruby, these two points for me were largely social, community issues.

26 September 2009

Pablo Lorenzzoni: Ruby versus Python

This is not another rant to praise one in spite of the other (an everybody knows I love Ruby, so it would not be impartial), but sometimes people seems to live in another world and do things for the wrong reasons. I just read this blog post by Kanwei Li in which he gives 2 or 3 reasons he ditched Ruby in favor of Python. First of all, both are great languages and, although I favor Ruby, I use Python for some projects and they are not all that different. Of course, everyone is free to choose which language one favors, but Kanwei seems to be ditching Ruby out of not knowing much about it, or out of preferring one style over the other His first reason is that in Python white spaces matter. I used to think this is just a matter of style, but every now and then mandatory alignment hurts me (just try to put together a code generator and you ll notice it). Although my code is always correctly aligned, I like that it s done so because I want it that way, and not because some language demands it. Rants and more rants have been written about Python s mandatory alignment (or other languages lack of it), and I am not going through all of it Just I don t think it s a good reason to ditch Ruby After, he makes a big deal out of Ruby s ternary if. As written by him, he prefers

#python
if len(a) > 0:
        v = a[0]
        a = a[1:]
else:
        v = None
over Ruby s ternary if

#ruby
v = a.empty? ? a.shift : nil
Hey! Come on Ruby s ternary if is not mandatory It was copied from C just as a syntax sugar. You can do without it, just as in Python:

#ruby
if ! a.empty?
    v = a.shift
else
    v = nil
end
Better yet! you can use if s return as v value:

#ruby
v = if ! a.empty?
    a.shift
else
    nil
end
How beautiful is that! Python lacked ternary if for a long time, and when it finally acquired one via PEP 308 its syntax was made different from every other language! Although I don t think that is a problem, some people might think it would be better not reinventing the wheel. Next, Kanwei goes over a famous problem of Ruby: the lack of a sum method for Array. I admit it s strange, but that is completely coherent: Ruby s Arrays are ordered collection of objects and not mathematical arrays. How do you sum objects that are not numbers? Many different people will have many different answers to that, so Ruby leaves this decision for the programmer and provides basic methods to deal with collections of anything (that can be used to apply sum to numbers, if wished). So, in Ruby you have to use Array#inject to perform a sum:

[1,2,3].inject(0)    sum, value  sum + value  
Array#inject (actually Enumerable#inject) was borrowed from Smalltalk and allows you to loop through an array, building up an accumulator value as you go. When it s done, the final value of this accumulator is returned. Very useful for combining array elements, whether by summing them, building up a pretty display string, whatever. In the example above, I am initializing the accumulator with 0. If you use Array to mathematical operations and you want your arrays to work that way, you can always add a sum method to Array class:

class Array
    def sum
        self.inject(0)  sum, value  sum + value 
    end
end
Maybe it would be better if you just use Arrays as containers (as it was intended to) and implement that sum inside your own class I completely agree with Reg Braithwaite here. Kanwei also mention Python is faster than Ruby. That is true, but was more true some time ago. First of all, Python is older and has had more time to improve its speed. Ruby, ITOH, just now acquired a good VM and improvements to it finally can run parallel to improvements in the language itself, so I am expecting this to be less true every release. Python is already not getting much faster between releases, unlike Ruby (the differences between 1.8.7 and 1.9.1 are really impressive!). IMHO this is not a good reason to choose one instead of the other: if you really need speed, go for C :-) Now this is something I find interesting Kanwei has mentioned: Python is more production ready . He argues that Google is using it, so it must be good. Well I cannot argue against that: Google is really using Python. But IBM, Oracle, EA, Cisco, Siemens, etc are using Ruby so that is just a matter of preferring one or another company. Both are production ready I agree, though, that Ruby 1.9.1 has many differences from 1.8.7, and that that may be seen as some inconsistency, but Python also has changed a lot since its 2.0 version, for that matter. And the changes to Ruby brought many benefits I think they worth it. At last, Kanwei compares Python and Ruby docstrings. Here I also have to agree with him: Ruby docstrings sucks. Actually that s why everybody uses rdoc instead (and that is much more powerful than Python s docstrings). Again, I don t think that is reason enough to ditch Ruby (actually, the existence of rdoc, rubygems & friends should bring people to Ruby instead), but that is a matter of personal taste. Surely, Kanwei s reasons were easy to argue against. There are areas were Python shines much more than Ruby (and vice-versa), but those Kanwei mentioned are not among them. I think both languages are powerful enough, and both are way better than Perl or PHP, so either one you choose would be fine. Better if you don t have to choose and use both ;). If you have to, ITOH, pay more attention on how you feel while coding in each one, and not to some cheap reasons such as above. If you are a programmer, what matters most is that you ll spend a lot of time coding with any given language let that be something pleasant then.

16 September 2009

Robert Collins: Back from hiatus


Well, the new blog seems to be up and running and gathering modest numbers of comments already. Woo. I ve a bunch of mail about test suite performance to gather and refine into a follow up post, but that can wait a day or two. In bzr we suffer from a long test suite, which we let grow while we had some other very pressing performance concerns. 2.0 fixes these concerns, and we re finding the odd moment to address our development environment a little now. One of the things I want to do is to radically reduce the cost of testing inside bzr; code coverage is a great way to get a broad picture of what is tested. Rather than reinvent the wheel (and I ve written one to throw away, so far) are there tools out there that can:
  • build a per-test coverage map
  • do it quickly
  • don t include setUp/tearDown/cleanUp code paths in the map
  • report on the difference between two such maps (at the suite level)
The third point is possibly contentious, so I should expand on it. While code that is executed by code within the test s run() method is from the outside all part-of-the-test, its not (by definition) the focus of the test. And I find focused tests substantially easier to analyse failures in, because they tend to check preconditions, poke at object state etc. As I want this coverage map to help preserve coverage as we refactor the test suite, I don t want to include accidental coverage in the map.

10 September 2009

Pablo Lorenzzoni: Code testing coverage

I like building tests for my code. That is not an old habit, it s just something I ve been developing in the recent months or some few years. No, I am not doing TDD (although that doesn t sound like a bad idea): I just build tests after I code as a safeguard to be sure I haven t broken anything. I suspect there are more programmers like myself than those using tests as part of a TDD (BDD, SDD, etc) approach, but that is just an opinion. Well I just recently became found of code coverage estimates and tools, and rcov is such a nice tool that sometimes I just find myself building tests just to please it. I also suspect there are at least a bunch of people that do the same. Here are the results of the test coverage of one of my projects:

spectra@rohan:~/work/xmpp4r-observable$ rake rcov
(in /home/spectra/work/xmpp4r-observable)
rm -r coverage
Loaded suite /usr/bin/rcov
Started
........................
Finished in 70.995814 seconds.
24 tests, 97 assertions, 0 failures, 0 errors
+----------------------------------------------------+-------+-------+--------+
                   File                                Lines    LOC     COV    
+----------------------------------------------------+-------+-------+--------+
 lib/xmpp4r-observable.rb                                648     414    61.4%  
 lib/thread_store.rb                                      58      39    87.2%  
 lib/observable_thing.rb                                 187     118    91.5%  
+----------------------------------------------------+-------+-------+--------+
 Total                                                   893     571    69.4%  
+----------------------------------------------------+-------+-------+--------+
69.4%   3 file(s)   893 Lines   571 LOC
spectra@rohan:~/work/xmpp4r-observable$
Sure it s tempting to get more of lib/xmpp4r-observable.rb covered, isn t it?

6 September 2009

Torsten Werner: 10 years in Debian now

I think this was my first contribution to the Debian operating system:

grace (5.0.3-1) unstable; urgency=low

* added Replaces: xmgr, closes #35010, #42115, the only conflicting
file is the grconvert binary which is identical in both packages
* changed editor to sensible-editor
* redebianized using dh_make and debhelper
* new upstream, closes: #41146, #27308, #28944, #29705, #38214
* NMU

-- Torsten Werner Mon, 6 Sep 1999 22:19:04 +0200

That was 10 years ago. By the way the package is still in the distribution but orphaned now. Please note that our bug numbers had 5 digits only!

I don't want to count the packages that I am involved today but I am concentrating on Java related stuff. We got OpenJDK into Lenny and since DebConf9 it is our default JDK. Thanks to the recent work of Ludovic Claude we can use Maven for building official Debian packages. That will hopefully make packaging easier for many packages where upstream is using Maven as the build tool. I recommend joining the debian-java list if you are interested in those topics.

And I am a member of the FTP team today which is a great honour. It is quite
some extra work but we are now closer to the 1 week waiting time for NEW
processing (on average). Processing NEW is another place where I could see that
times are changing: this week I accepted a package (c) Microsoft Corporation
into Debian main what seemed to be impossible ten years ago.

3 September 2009

Pablo Lorenzzoni: EeePC: Surviving liquid spills - phase II

About four months ago I described how my EeePC survived the spilling of orange juice over its keyboard. No! I never spilled anything on it again, if that s what you re thinking But I noticed that some keys (those that got more juice on) began to malfunction. At the beginning I paid no attention to it, hoping that it would just go away, but, eventually, they just stop working And those are not just unimportant keys I am talking about arrows and the forward-slash (/) keys in the lower right corner of the keyboard!!! How could I survive without those keys, without a quick access to my bash history and vim search? Well, I began googling around and found some good advice. Everything that made sense regarding how to cleanup my keyboard I compiled and, when I was enough confident it would work, I just follow the procedure I ve devised. This is what I did:
  1. After turning it off and removing the battery, I removed the keyboard. Check the instructions I linked in my previous article for some pictures on how to do it.
  2. I poured 500 mL of distilled water in a clean plastic box (I bought 1L for BRL 20 at a local pharmacy), added enough dish detergent to make some foam (I was careful to select a non-biodegradable one) and drowned the whole keyboard in the solution.
  3. For the next 30 minutes I pressed and released the affected keys over and over again. My intention was to dissolve anything that might have remained from the orange juice.
  4. I left it soaking in the solution for the next 12 hours.
  5. The next day I got the keyboard out of the solution and used current tap water to remove any detergent still left in it. This might have took about 10 minutes.
  6. Our tap water is really clean, but its hard, and I would not like to remove any juice from the keyboard just to add some minerals that might have the same effect, so after I was certain all the detergent was removed, I left the keyboard in the remaining of the distilled water for another 12 hour soak.
  7. After that I just removed the keyboard from the soak, dried it a little bit using a paper towel and left it to air-dry (away from the sun). I don t remember how long it took, but I believe not more than 4 hours Those were hot days Anyway, I was really sure it was dry.
When I plugged it back, surprise! All keys are working again! Of course, that was just what worked for me Best advice still is: Keep liquids away your EeePC!

3 June 2009

Pablo Lorenzzoni: Keysigning Party at FISL10

We ll be holding a Keysigning Party at FISL10. This will be a good opportunity to renew my key, given I ve been using it since 2001 and it s an old 1024 DSA key. I have to thank An bal Monsalve Salazar and Alexander Wirt for sharing their expertise in organizing this kind of event. More information on the KSP can be obtained from the announcement.

30 May 2009

Steve McIntyre: age++

On Thursday it was my birthday, and I fulfilled a promise I made to myself many years ago. I've always been a car nut, and when I was about 6 years old and had posters of Lamborghinis on my bedroom walls I promised myself that by the time I reached 35 I would have one. That would be long enough in the future that it might happen, but I'd still be young enough to still be able to appreciate it. Well, as it got to the beginning of this year I realised I was running out of time and my bank balance didn't quite look large enough to buy a Lamborghini. So, I cheated a little and I hired one for the day on Thursday. Toy! More pictures here. I had one car booked a few weeks ago, but unfortunately the company involved had to let me down as the car developed problems a couple of days before I was due to have it and needed to go away for repairs. I'm not going to complain too much about them, as it wasn't their fault and they did their level best to make things right: offering a different car, a refund or a later replacement hire. But dammit! I wanted the Lamborghini and I wanted it on my birthday! I quickly rang around on Wednesday to find somebody else, and thankfully the folks at Signature Car Hire were very helpful, sorting out a car with just a few hours' notice. Yay! When they guys turned up on Thursday morning to deliver the car to my office, I couldn't stop myself grinning like the 6-year old boy whose promise I was keeping. Here was a gorgeous car, and it was mine for the day!!! I planned a route for the day to take in some nice driving roads and, importantly, some tunnels. I've watched Top Gear on the TV and I read Autocar every week, and they had both said that taking a fast sports car through a tunnel with the roof down was a good thing to do. I now know that's an understatement! As a whole, the car was awesome: the acceleration, the handling, the brakes were all wonderful. But, as I found out on that day, the noise from the engine was just astonishing. I went through several tunnels that day, heading down past Baldock to Hatfield and back, and at full throttle I could not help but laugh out loud at the music coming from the 5-litre V10 orchestra just inches behind me. It's an experience I'm never going to forget. grin. I also gave short rides to quite a few of the people at work; oddly I had lots of friends that day... :-) I'd also planned other things for the day. I bought myself a new camera in advance to make sure I got some nice photos of the day. Then at the end of the day I went out to the pub with a huge group of friends and I was forced to drink lots of beer. It was horrible, horrible I tell you.

18 May 2009

Sven Mueller: Link collection 2009/05/18

That s it for now, will update the post if I find more interesting links in the next few days.

16 May 2009

Pablo Lorenzzoni: Inspiring picture

Just this week I went to the movies to check the latest incarnation of Cap. Kirk, Mr. Spock et al. It really was a great movie I was expecting less, I have to admit. But the movie was not bad at all With all that space and beyond thing in my mind, yesterday I was surprised with a greatly inspiring picture taken from Hubble Florida, before STS-125 reach Hubble (thanks Florian Weimer for the heads-up): How inspiring can that be? You can find the original here, along with the explanation of how and when it was taken.

7 May 2009

Pablo Lorenzzoni: Another small victory - don't relax just yet

Months (even years) of activism, over 140 thousand signatures, and finally another small victory: Brazilian Minister of Justice Mr. Tarso Genro sent a letter [pt-BR] stating that Sen. Azeredo s bill is dangerous, and that the Ministry is working in an alternative (among other things). We had already incited a public hearing that were very fruitful [pt-BR] and might have brought the Ministry to the issue. But don t relax just yet, folks! Right now, working in this alternative , are people with every kind of agenda It s safe to assume that some of them are from the same lobby that pushed Sen. Azeredo first version of the thing. So, yes, this was another victory, but nothing really changed The bill is still approved by the Senate and still has to be reviewed by the Chamber-of-Deputies, and the alternative that will be presented by the Ministry is still under construction. What we accomplished is nothing more than making the Minister aware of the issue So, keep the pressure over your representatives, send messages to the Ministry, stating how you feel about the issue! Let s show them what we want them to do After all, that s why we elected them, in the first place, isn t it? [Published also at Trezentos, in portuguese]

4 May 2009

Manoj Srivastava: Manoj: Reflections on streetcars

Recently, I have made fairly major changes to kernel-package, and there were some reports that I had managed to mess up cross compilation. And, not having a cross-compilation tool chain handy, I had to depend on the kindness of strangers to address that issue. And, given that I am much less personable than Ms Vivien Leigh, this is not something I particularly look forward to repeating. At the onset, building a cross compiling tool chain seems a daunting task. This is not an activity one does frequently, and so one may be pardoned for being non-plussed by this. However, I have done this before, the most recent effort being creating one to compile rockbox binaries, so I had some idea where to start. Of course, since it is usually years between attempts to create cross-compiling tool chains, I generally forget how it is all done, and have to go hunting for details. Thank god for google. Well, I am not the only one in the same pickle, apparently, for there are gobs of articles and HOWTOs out there, including some pretty comprehensive (and intimidating) general tool sets to designed to create cross compilers in the most generic fashion possible. Using them was not really an option, since I would forget how to drive them in a few months, and have a miniature version of the current problem again. Also, you know, I don t feel comfortable using scripts that are too complex for me to understand I mean, without understanding, how can there be trust? Also, this time around, I could not decide whether to cross compile for arm-elf, as I did the last time, or for the newfangled armel target. A need for quickly changing the target for the cross compiler build mechanism would be nice. Manually building the tool chain makes a wrong decision here expensive, and I hate that. I am also getting fed up with having to root around on the internet every time I wanted to build a cross compiler. I came across a script by Uwe Hermann, which started me down the path of creating a script, with a help option, to store the instructions, without trying to be too general and thus getting overly complex. However, Uwe s script hard coded too many things like version numbers and upstream source locations, and I know I would rapidly find updating the script irritating. Using Debian source packages would fix both of these issues. I also wanted to use Debian sources as far as I could, to ensure that my cross compiler was as compatible as I could make it, though I did want to use newlib (I don t know why, except that I can, and the docs sound cool). And of course the script should have a help option and do proper command line parsing, so that editing the script would be unnecessary. Anyway, all this effort culminated in the following script: build cross toolchain, surprisingly compact. So I am now all set to try and cross compile a kernel the next time a kernel-package bug comes around. I thought that I would share this with the lazy web, while I was at it. Enjoy. The next thing, of course, is to get my script to create a qemu base image every week so I can move from user mode Linux to the much more nifty kvm, which is what all the cool kids use. And then I can even create an arm virtual machine to test my kernels with, something that user mode linux can t easily do.

30 April 2009

Pablo Lorenzzoni: EeePC: Surviving liquid spills

Last few months since I got my EeePC have been a lot of fun. Playing and tweaking the little bastard is a joy in the end of a busy day. Besides, since I loaded it with the most useful SysAdmin tools, it became a powerful device in my tool belt . Unfortunately, I ve been stupid enough to drink a glass of orange juice while messing with it. I know, I know! Silly thing to do. I should know better! But life is like that I spilled a few drops over it. Of course, the web is pouring off information on what to do in cases like this, so I ll just summarize what I did:
  1. Imediatelly, without thinking or questioning, I turned it upside down and removed the battery. It was a clumsy thing to do I ended up spilling the rest of my orange juice on the floor while worrying about the EeePC. Concearns about filesystem corruption (or whatever) crossed my mind, but I can always deal with that later First things first!
  2. I went online in another computer and found out how to disassemble it. For me it was easy, since I got other two computers at home but if I needed to leave it there while looking for information, I would! If it s upside down and has no power whatsoever (the battery was removed), it s safe, I think. The information was easily found. I decided I didn t need to disassemble all of it, but having those information at hand was pretty useful.
  3. I began by removing the keyboard. It s tricky but not difficult. The secret relies on the spring-mounted tabs near the screen. I checked for spills under it and cleaned with a cotton swab.
  4. I was not very confortable to open the case, but I decided that turning it back on without checking the electronic parts first was too risky. So I said goodbye to my warranty and unscrewed the 6 screws from the bottom and the 9 from the silver casing under the keyboard.
  5. There I found some little drops! Good decision to open it up! I dried it using cotton swabs again.
  6. Before putting it all together, I decided to leave it open until the next day. I was pretty sure everything was dry again, but better safe than sorry . The next day I successfully assembled it and turned it on. Great! Everything worked fine.
Now that was just what worked for me. My EeePC is back, fully restored but, of course, the warranty is void :-( So I cannot recommend you to do the same. Best advice I can tell you: Keep liquids away your EeePC!

22 April 2009

Gunnar Wolf: Rodrigo denying evasions and religion

Umh, is today the quote your neighbour day? No? Thought so... Still, for the second time in a couple of minutes, I'm quoting/translating here. This time, I'm quoting a short text posted by fellow Mexican Debian guy Rodrigo Gallardo: Deceptions (hmm... Not in the let you down sense, but in the deceiving sense. Sometimes it is hard to translate a single word without twisting it around). My translation is far from perfect - Read it in Spanish, you will enjoy it more. Rodrigo says:
Things and actions are what they are, and the consequences of them will be what they will be; why then should we desire to be deceived? Joseph Butler
I was in Colima, sitting on a slide in a city park, that day I understood why somebody might want to be drunk. Several years later, this time in Tlalpan, I understood why somebody would want to believe in a god. And sometimes I am truly sorry not to be able to embrace neither of both longings. The idea of letting go the facts, to believe they have an inner order, although covered in mistery, or they are just far away, blurry. But where others see destiny, I see things falling naturally in their place. Where others see beauty in the mistery, I see a challenge. And even more beauty in an elegant explanation, in understanding. Motivation, not in the promise of future welfare but in the certainty of this limited but tangible present welfare. Freedom in the absence of a purpose, and inmortality in the little pebble I am in the great human building. I suppose that if Revernd Butler knew his phrase inspired this divagation, it would not make him precisely happy. But, things are what they are, and his argument says what it says.

15 April 2009

Pablo Lorenzzoni: rsync logs with restricted ssh

SSH is really the Swiss Army pocket knife of sysadmin tools. When I needed to periodically synchronize log files from an old server (old as in customer-would-never-update-it-or-install-anything-new), I built a simple and secure solution using rsync and ssh. This is what I did: (I will call remote the system where the logs I want to retrieve are, and local system where I want them to be copied to) First I created an account with a restricted shell (ideally this should be a system account, but we ll get there!):

remote# adduser --ingroup nogroup --shell /bin/rbash rlogs
Then locally, I created a new, password-less ssh key pair, copying it to my remote system:

local$ ssh-keygen
>>> When asked where to save it, I chose a different name, like .ssh/rlogs
local$ ssh-copy-id -i .ssh/rlogs.pub rlogs@remote
...
>>> You can delete the password of user rlogs, so it, effectively,
>>> cannot log-in with it (almost like a system user).
remote# passwd -d rlogs
Now you should be able to run password-less rsync already (note that I use -e option to point to a different key):

local$ mkdir logs
local$ rsync -av -e "ssh -i $HOME/.ssh/rlogs" rlogs@remote:"logs/" logs/
receiving file list ... done
./
file1
file2
...
fileN
But even with a restricted shell, I wanted even less possible things to happen. That s what command= directive is for It will only allow that command to be run in a session started by that key. Since rsync translates a lot of its command-line options, I run it again with a dirty ps-in-a-loop in the remote host, just to see what running rsync locally causes remotely:

remote$ while 1; do ps wp $(pgrep rsync); sleep 1; done
...
local$ rsync -av -e "ssh -i $HOME/.ssh/rlogs" rlogs@remote:"logs/" logs/
>>> in the remote loop you should be able to get the command:
  PID TTY      STAT   TIME COMMAND
 6183 ?        Ss     0:00 /usr/bin/rsync --server --sender -vlogDtpre.i . logs/
Here comes the authorized_keys magic. At the remote host I edited .ssh/authorized_keys to add a command= line with what I found out in my dirty loop. Also, I added a couple of directives to restrict it even further (they are pretty self-explanatory):

rlogs@remote$ cat .ssh/authorized_keys
command="rsync --server --sender -vlogDtpre.i . logs/",no-port-forwarding,no-agent-forwarding,no-X11-forwarding,no-pty ssh-rsa (...) myuser@local
Now everything is set. I just added the rsync command to the local crontab and it s done.

8 April 2009

MJ Ray: Why is public and charity money paying for the private sector s marketing?

The workshop I went to recently and the ICT Champions in general ( Website Under Development - release early, anyone?) seem to be funded by public and charity money. As I mentioned, the worst thing was all the needless promotion of certain companies products, so why are they promoting private products instead of being neutral and open? That s bad for Britain, bad for the competing products that are co-produced by the Voluntary and Community Sector and bad for the VCS workers because it trains them in single-tool methods instead of transferable skills. Let the private sector pay for their own adverts! Why can t we stop making this mistake? Which brings me to the other problem with that ICT advice: well-meaning common-sector businesses like ours can t update it autonomously, for two reasons:
  1. All the texts I saw were under various Non-Commercial and No Derivative licences which make them hazardous or unusable to IT support businesses.
  2. Particularly on Free and Open Source Software, the advice is at best misleading and unhelpful. This is very frustrating: based on our private work and success in explaining things, I m sure we could do better, but for various reasons, no-one is paying for us to publish that. Instead, someone s paying to publish statements like There s no such thing as open source written by someone from an association that includes Microsoft and Oracle.
Again, why is public and charity money paying for the private sector s marketing? Why is it published under blocking copyright terms, scattering broken glass across the path just built? Where can we get funding to publish our explanations?

7 April 2009

Gunnar Wolf: map $_->destroy $home->windows; waitfor(NewWindows->arrive) && $home->build_windows;

I live in a 55 year old house. That's not something to be worried about, of course, but it does mean that my house needs major maintenance works to continue to be in good shape. This week, said major maintenance jobs began. We are in the process of replacing all of the windows - It might sound a bit scary by today standards... But if you have ever been here... Well, this house was built in a very different era, when the newly built University City lied several kilometers South of the city border and land was cheap here. Most houses in the area were built for University teachers (this particular house was for twenty years home to Marcos Moshinsky, Mexico's most important Physicist who, coincidentially, passed away last week; Dr. Moshinsky was my father's teacher and mentor). Anyway, we just started the window teardown process. The workers are going quite faster than I expected. Still, I am worried about the waitfor(). As anybody who has come to this house will know, we live on a very busy avenue. Even 30 years ago, when my parents moved here, they installed double glasses on every window - But did some mistakes (i.e. we have some broken glasses which are unchangeable for practical purposes). This time we decided to buy from an established vendor for this kind of windows. Double-glass windows are common in colder regions - But here, they are quite rare. Strange, being this a noisy city... So we researched a bit, and found a vendor with good quality - Multivi, in Puebla. What we didn't count on... Is that they were so informal. We paid in late December and were told delivery would take around two months... And we are still waiting, this time pressing them for a commitment. After all, we are already lacking several windows, and... Well, around May we start having rains. We DEFINITIVELY don't want to be stuck without windows by May! Anyway... I recently sent out a semi-VAC anouncement to debian-private. And this is extensive to any project I am related to: The next days I will be paying more attention to whatever needs to be done at home. Please don't expect prompt replies to mail from me (yes, as if I usually replied promptly...) I do have network access, but not much computer time.

25 March 2009

Pablo Lorenzzoni: FISL10 Subscriptions and Call for Papers Opened

One of the largest FLOSS events in the world, FISL (International Free Software Forum in english) subscriptions are already being accepted. They also already called for papers! They re calling this year s a special edition since they expect to reach 10-thousand attendees (last year exceeded 7-thousand)... this is pretty big if you ask me. As usual, it will take place at Porto Alegre, and is scheduled from June 24th to 27th. I think we can expect the usual activities (Programming Arena, Interesting Workshops, FLOSS shows, Great Speakers, Brazilian Government), but I think the special edition is not just due to the number of attendees. What surprises are being cooked by the Organization Committee is just something we ll have to wait and see :-) See you there!

18 March 2009

Pablo Lorenzzoni: PubSub with XMPP4R-Simple

As I already told you, I am using XMPP4R-Simple in an internal project. For this, I d have to add PubSub capabilities to it, and I did when I decided to get serious with git. Today I committed a version with integration of various patches by other forks I found on GitHub plus a lot of improvements on PubSub functions. With this version it s simple to use PubSub like this:

require 'xmpp4r-simple'
# Simple function just to parse an event
require 'time'
def parse_event(event)
  item = event.children[0]
  node = item.node
  time = nil; item.each_element("//published")    e  time = Time.parse(e.text)  
  text = nil; item.each_element("//body")    e  text = e.text  
  return   :item => item, :node => node, :time => time, :text => text  
end
# Create the clients
im1 = Jabber::Simple.new "im1@example.com", "password" 
im2 = Jabber::Simple.new "im2@example.com", "password" 
# im1 creates a node
im1.create_node("/some/node")
# im2 subscribe to that node
im2.pubsubscribe_to("/some/node")
# We'll start a simple thread to get the events coming from that node to im2
Thread.new   loop  
  sleep 1 while ! im2.received_events?
  im2.received_events    event 
    h = parse_event(event)
    puts ">>> Got an event from node # h[:node]  published at # h[:time]  with text # h[:text] " 
   
 
# Now im1 just publishes anything to that node.
im1.publish_atom_item("/some/node", "This is my node", "This is the content of my node")
# The thread should capture the event and run puts on the hash from parsing.
PubSub is great, isn t it?

Next.

Previous.