Archive | OpenSource

Open Source means that users have the freedom to see how software works, adapt it for the own needs, fix bugs and limitations and contribute back to the community.

Notes from PySIG, 29-Nov-2007: Django in the real world

Fourteen people managed to find their way to the Amoskeag Business Incubator (it’s on SOUTH Commercial Street, contrary to the directions on the ABI site) for the November meeting, one week later than the usual fourth Thursday of the month, of the Python Special Interest Group.

A number of new attendees arrived this month. We pointed out that the mailing list for the group can be found on the DLSLUG and GNHLUG sites, look for “mailing list” and that there was an announcement as well as a discuss list for the group. We pointed out the main calendar at GNHLUG.org as well and talked about other resources.

Several members were new to the area or had come up from Cambridge, MA (our fair city) for the SIG meeting. They pointed out the Cambridge Python Group, who usually posts meeting announcements on Meetup.com, which boasts 103 members on their list! We discussed the ideas for mutual cooperation, and will be glad to cross-post their announcements to the PySIG -announce list.

Kent S. Johnson was the main presenter, and showed us how Django is used to host the http://www.blogcosm.com site. Without going into details on the business aspects of the site, Kent was able to give us a tour of several of the pages, talk about the RESTful URL formats, the model-view-controller model that’s used, demonstrate some of the code used to describe a model and the actions that can be taken on it, and show us some of the templating language that generates the HTML. The built-in administrative functionality, creating simple CRUD pages based on the model descriptions, was an impressive Django feature.

An excellent meeting, with lots of code and lots of ideas. Thanks to Kent for the main presentation, to our Cambridge brethren for making the long trip, to Bill Sconce for arranging, announcing and MC’ing the meeting, and to the Amoskeag Business Incubator for providing the great venue. Hope to see you all again at next month’s meeting, held on the 27th of December, likely just an informal chat due to the proximity with the holiday.

Ivan Krstić, First OLPC deployment: now it’s real.

Ivan Krstić blogs First OLPC deployment: now it’s real.: “This week, Uruguay became the first-ever real, non-pilot deployment site of OLPC XO laptops. And I was there to hand out the first one.” Very cool! Uruguay is due to deploy ninetu thousand and Peru just signed up for a quarter of a million of them. The pundits can say what they want, but the experience in the field will be far more educational than the prognostications. Looking forward to the results.

On The Media talks with WSJournalist about the One Laptop Per Child

On NHPR this morning, the On The Media show had an episode on the One Laptop Per Child program. Here’s what they say on their web site:

In 2005 computer scientist Nicholas Negroponte announced his bold plan to build a laptop that costs $100 and deliver it to the world’s 150 million poorest schoolchildren in just 4 years. But the Wall Street Journal’s Steve Stecklow says competition from companies like Intel and Microsoft seems to have put that goal out of reach.

I’d be disappointed if the OLPC itself doesn’t succeed, but in some senses, it already has, spurring innovation (real innovation, not marketing slogans) in the low-power rugged laptop-form-factor marketplace. OLPC is radically innovative hardware where many of the other version one-oh products are the same old stuff in a smaller case. OLPC has screen that works in full sunlight and uses little to no power as an eBook. It has a mesh-based network capability that will allow ad-hoc networks over great distances in field conditions. Every aspect of the design was considered. These are elegantly engineered machines. The software is as innovative as the hardware, with a simplified UI that allows and encourages exploration and collaboration. I’ve contributed to the project, and I encourage you to do so.

Recommendations for FOSS podcatcher?

I listen to audiocasts (I don’t have a *pod, and don’t agree with the brand implications. Since I listen on my ThinkPad, they’re PadCasts for me. Let’s say “audiocast” or we could be really retro about it and refer to them as “audio recordings” since they’re neither cast nor podded.) while working out and go through quite a few. The Conversations Network has been a great source for these: IT Conversations in particular. Phil Windley’s Technometria is one I try to catch each weekly episode. Other features, like David Heinemeier Hansson’s keynote at the 2007 RailsConf or Tim’ O’Reilly’s keynote as OSCON are other favorites. There’s lots of other good stuff on Coversations Network, so much so that I’ve contributed to the network, a non-profit 501(c)(3) organization.

But there are other, far smaller operations. I met Peter Nikolaidis through the Dartmouth Lake Sunapee Linux User Group, and he does an audiocast called “Fresh Ubuntu” with a fellow from the west coast named Harlem, a man with a voice for radio. An interesting show with contributions from many others, too, focused on Ubuntu, but ranging over many of the topics involving Open Source.

I like to keep up with all of these audiocasts (and would welcome more recommendations from others!), but it involves manually visiting the web site, checking to figure out if I’ve heard the audiocast already, and downloading it. I’m looking for an automated way of doing this.

I was (and still am!) a regular subscriber to Dave Winer’s Scripting News, and listened to his first audio enclosure (imagine that!) in his RSS feed, accessible directly through the Radio Userland built in feed reader. Since then, I’ve changed hardware a few times, operating systems at least twice, and feed reader software more times than I can recall. I’m looking for an application I can run from my Linux desktop that will regularly check the RSS feeds put out by the audicasting sites and download the new audiocasts of interests. Bonus points if the software is under a FOSS license, +1 for efficient and frugal resource use, cool interfaces, etc.

One recommendation off the Conversations Network is labeled iPodder, but points to JuiceReceiver, which doesn’t “yet” have a Linux port, despite being written in Python. It seems like there are close relatives to this code in CastPodder and IcePodder, but it’s not clear to me which of any of these projects is alive, well and legitimate. It appears to me that IcePodder has roots in the others, with directories still named iPodder (likely renamed due to near trademark infringement of a well-known player?) and a CastPodder manual buried in the download, dated 2005. (Here’s a clue: IcePodder’s About page says “IcePodder is a podcatcher (RSS client) for Linux conceived as a replacement for CastPodder. ” So my guess is that iPodder begat JuiceReceiver begat CastPodder begat IcePodder. Whether or not I’m on the “right” branch is something that a little more research ought to bring to light. (Update: a little Googling confirms the theory, and it appears to be pretty amicable.)

IcePodder was an easy install: download, unpackage, review the README and INSTALL, review and run the install.sh script. Written in Python, using wxWidgets for UI, GPL. A little shaky in operation – I’ve crashed it once or twice, but I’m running the old “stable” release rather than the current code, so I should upgrade before passing judgement. The code needs some serious search-and-replace s/CastPodder/IcePodder/g but it looks pretty promising. Anyone else have recommendations?

UPDATE: gPodder also looks promising. Don’t let the version 0.10 fool you – apparantly, that’s the version after 0.9, according to the developers…

Retro-tagging a WordPress blog

I’ve got a WordPress blog with a couple thousand posts, upgraded several times, from a TWiki blog to a Radio Userland blog to WordPress and a couple of upgrades. And I’d like to add the new taggin features available in WordPress 2.3. Here’s what I’ve figured out from poking around: what used to be wp_category is now wp_terms and terms contains both categories and tags. The categories are hierarchical from a self-join using the group column to link back into the term’s term_id primary key. wp_terms in turn links into wp_term_taxonomy: that’s got a column named taxonomy that contains groups like ‘category’ and ‘link_tag’ and a parent column that self links into term_id, which I think is a duplication of what wp_terms is doing. There’s also a count field, meaning that we’re denormalizing the count of categories and tags, meaning if we hack at them, we’ll need to manually update this (see below). Finally, the posts are related to categories and tags using the table wp_term_relationships that’s a many-to-many link from the post’s primary key, object_id, to the term_taxonomy_id primary key of the wp_term_taxonomy table.

So, here’s the recipe to retrofit tags into some posts. I used phpMyAdmin as the web interface into the MySQL table that holds WordPress’ data. You can do the same via the mysql terminal interface or using other remote connectivity like ODBC or your choice of tools.

1. Create or update a tag in the wp_terms table. Note the term_id PK.
2. Insert the term_id and category of ‘post_tag’ into the wp_term_taxonomy table.
3. Create the linking records in wp_term_relationships with the following SQL. In this case, I’m tagging with “Ruby” any post that has “Ruby” in the title or post.

INSERT INTO wp_term_relationships
SELECT wpp.id object_id, `term_taxonomy_id`
FROM wp_posts wpp, `wp_term_taxonomy` wptt
JOIN wp_terms wpt ON wptt.term_id=wpt.term_id
WHERE wpt.name='Ruby'
AND wptt.taxonomy='post_tag'
AND (wpp.post_content LIKE '%Ruby%'
OR wpp.post_title LIKE '%Ruby%' )
ON DUPLICATE KEY UPDATE
wp_term_relationships.term_taxonomy_id=
wp_term_relationships.term_taxonomy_id

(The ON DUPLICATE code is just a quick hack to tell MySQL to ignore it if you’ve already tagged some posts Ruby by hand.)

4. Hack away. When you’re all done, you’ll want to fix the count in the table with the code below:

UPDATE wp_term_taxonomy wptt
SET wptt.count=
(SELECT count(*)
FROM wp_term_relationships wptr
WHERE wptr.term_taxonomy_id = wptt.term_taxonomy_id
GROUP BY term_taxonomy_id)

Fedora 8 Everything Spin Released! — Fedora Unity Project

The Fedora Unity Project announces Fedora 8 Everything Spin Released!: “The Fedora Unity Project is proud to announce the release of new spin, the Everything Spin. Included in this spin are all the packages available at the time Fedora 8 was released.”

A neat feature of recent ( 7 & 8 ) Fedora releases is the ability to create your own derivative distributions based on the tools supplied with the package. This allows the LiveCD and LiveUSB features I mentioned earlier, and allows independent groups to create specialized disk images (“spins” in their inside chatter) to meet specific needs, in this case, a set of CDs for those who don’t have a DVD handy. I ran into this situation recently with a customer who had chosen to economize on his server specifications by cutting out a DVD that was likely to be used only a few times over the lifetime of the hardware. It’s cool that the Fedora build process has been made public and the tools to do this added to the distro itself.

Red Hat Magazine | I am Fedora, and so can you!

Max Spevack, the benevolent dictator in charge of herding cats for the Fedora project, doesn’t announce the official release of Fedora 8 today in his posting, I am Fedora, and so can you! in Red Hat Magazine, but it’s out there. (His post is actually a great HOWTO on running Fedora off a USB memory stick, neat trick that that is!) Find the bittorrents and conventional downloads at http://fedoraproject.org/get-fedora and hop aboard. I run Fedora, and so can you!

Powered by WordPress. Designed by Woo Themes

This work by Ted Roche is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 United States.