Archive for August, 2008

What’s a Smokebot?

Monday, August 18th, 2008 by Andrew Moore

I recently put into place a few tools that should make automated testing of Koha a bit easier. The first is an installation of smolder that will graphically display the results of the test suite. The other is an addition to the test suite to make it easier to send reports to smolder. I have set up a cronjob to run the test suite twice a day and send the results into smolder. Some people call that a “smokebot,” since it’s an automated way to perform smoke tests.

I’m hopeful that this will help is in a few ways. One is that it may make it easier for us to catch those instances where a new patch will break some existing functionality. If there’s an automated regression test to verify some functionality and it stops passing at some point, we can use the smolder to tell when it stopped working. That may help us track down the cause of the failure.

The other way that this might help is is to increase the number of platforms that koha works on. If we start getting test results from other platforms or architectures, we can become more confident that koha works in other environments.

If you have questions about how to use the test suite in Koha or how to use smolder, please don’t hesitate to ask.

Koha 3.00.00 Released

Sunday, August 10th, 2008 by Joshua Ferraro

I’m happy to announce that Koha 3.00.00 has been released.

It’s available for download from the usual location:

http://download.koha.org/koha-3.00.00.tar.gz

Check out the release notes.

Interesting times for web developers

Thursday, August 7th, 2008 by Chris Catalfo

Here’s an interesting little post discussing the history of web applications, as well as some speculation as to their future: A little reminder or why.

I haven’t looked at what’s been happening with Java for a while, but these notes about Java SE 6 update 10 at Sun Developer Network certainly sound interesting.

I have actually installed a couple of Adobe AIR applications: ExtJS documentation as an AIR application and JQuery documentation as an Adobe AIR application. I’ve enjoyed using them both, as they provide a handy way to keep documentation offline.

These are interesting times, indeed, for (web) developers. So many languages, frameworks and technologies to choose from!

How to enable warnings, part one of many

Tuesday, August 5th, 2008 by Galen Charlton

Today I sent an RFC about turning on warnings in all of Koha’s Perl scripts and modules. Of course, turning on warnings by itself does nothing except fill up the Apache log; the trick is to quell them by fixing the underlying problems.

As an example, consider misc/migrations_tools/bulkmarcimport.pl. On the plus side, it already contains a use warnings; statement; on the minus side, it was commented out. So close!

After enabling warnings and running bulkmarcimport -d -file test.mrc, we get

deleting biblios
Use of uninitialized value in pattern match (m//) at \
 misc/migration_tools/bulkmarcimport.pl line 118.

One of the most common errors you after turning on warnings are complaints about uninitialized variables. So what’s the variable in question?


if ($format =~ /XML/i) {

OK, so what is $format and why is it uninitialized?


my ($version, $delete, $test_parameter, $skip_marc8_conversion, $char_encoding, $verbose, $commit, $fk_off,$format);

$|=1;

GetOptions(
    'commit:f'    => \$commit,
    'file:s'    => \$input_marc_file,
    'n:f' => \$number,
    'o|offset:f' => \$offset,
    'h' => \$version,
    'd' => \$delete,
    't' => \$test_parameter,
    's' => \$skip_marc8_conversion,
    'c:s' => \$char_encoding,
    'v:s' => \$verbose,
    'fk' => \$fk_off,
    'm:s' => \$format,
);

$format starts off with an undefined value when it is declared by my, and if you don’t supply the -m switch when running bulkmarcimport.pl, it stays undefined.

Fortunately, the script’s usage tells us what the default value of $formatshould be


  m      format, MARCXML or ISO2709 (defaults to ISO2709)

Thus, we can fix that particular warning with this patch:


--- a/misc/migration_tools/bulkmarcimport.pl
+++ b/misc/migration_tools/bulkmarcimport.pl
@@ -2,7 +2,7 @@
 # Import an iso2709 file into Koha 3

 use strict;
-#use warnings;
+use warnings;
 #use diagnostics;
 BEGIN {
     # find Koha's Perl modules
@@ -30,7 +30,8 @@ use IO::File;
 binmode(STDOUT, ":utf8");

 my ( $input_marc_file, $number, $offset) = ('',0,0);
-my ($version, $delete, $test_parameter, $skip_marc8_conversion, $char_encoding, $verbose, $commit, $fk_off,$format);
+my ($version, $delete, $test_parameter, $skip_marc8_conversion, $char_encoding, $verbose, $commit, $fk_off);
+my $format = "ISO2709";

 $|=1;

We’re not done with bulkmarcimport.pl, but this is a start. More anon.

BarCampOhio aka LibraryCampOhio

Friday, August 1st, 2008 by atz

Code4Lib folks and other techs around Ohio should consider checking out the upcoming BarCampOhio / LibraryCampOhio event on Monday August 11, 2008:

The idea is for a self-organized collaborative exchange, not a keynotable conference. So come prepared to share. OCLC will be hosting, with some very knowledgeable and interesting folks in attendance. And if you’re not into that, then you’ll still have me. :)