Canonical Voices

Posts tagged with 'opportunistic developers'

jono

Most of you will be familiar with Ubuntu One as the personal cloud service in which you can sync your files, buy music, and more. While the Ubuntu One team has been working hard to expand the end-user quality and experience of Ubuntu One, I wanted to share my experience with working with Ubuntu One from the perspective of an application developer.

A lot of people don’t realize that you can build support for Ubuntu One into your application and they provide a rather nice Python library to talks over DBUS to do this. Adding this support was simple.

The Ubuntu Accomplishments system was designed with Ubuntu One as a core piece. We didn’t use Ubuntu One because it had to be Ubuntu but instead that Ubuntu One solved a number of problems in building a decentralized application such as Ubuntu Accomplishments.

We wanted to be able to verify and validate accomplishments (so they can’t be faked), so we knew we needed a system in which we could transfer files over the network, process those files, sync the files back to one or more clients, and also provide a means in which you can view your trophies on any of your Ubuntu machines. Ubuntu One provided the ideal system for performing this syncing with the added benefits of being integrated into the Ubuntu experience.


Not that kind of sync.

So how does Ubuntu Accomplishments use Ubuntu One?

Like this:

  • When you load the application and enable support for verified trophies, it creates a directory on your computer and then marks it as an Ubuntu One share. It then offers the share to the validation service Ubuntu One user (which is just a regular Ubuntu One user that I tie some processing functionality to).
  • On the external machine (the validation server) I have a script that listens for Ubuntu One share offers and when the share comes in it accepts it.
  • When an accomplishment has been detected on the client machine the trophy is added to the share, which then automatically syncs to the validation server, and there we listen for an Ubuntu One signal to then kick off the verification. The signed trophy is then put back into the share which then syncs to the client.

As I mentioned earlier there is a Python module that I use to talk to Ubuntu One, and this not only provides methods to access all aspects of Ubuntu One (e.g. creating, offering, refreshing, listing, and subscribing to shares) but also provides a set of signals that you can connect to detect Ubuntu One sync events and handle them accordingly.

What is also nice, and lesser known in the community, is that you can run Ubuntu One on a headless machine. This is exactly what I am doing right now by running Ubuntu One an OpenStack image. You can find out how to set up Ubuntu One in a headless environment here.

Finally, many thanks to the Ubuntu Team for providing help and guidance for using their API.

Find out more about Ubuntu One app development features here.

Read more
jono

Yesterday I announced that the new Severed Fifth website is launched on Monday, and with it will begin the second phase of the project and the build-up to the second album. For the first album I ran out of steam as I had just signed up to do The Art Of Community for O’Reilly and this sucked up all of my spare time. I don’t want to make the same mistake again.

As such, I am keen to hand over some of my projects to new maintainers who can be sure to give them the time and focus that they deserve. Today I want to share some of the next next steps I would ideally like to see to provide some food for thought, and appeal for volunteers to take the reigns in these projects:

Acire

Acire is the project I created to produce a solid library of Python Snippets to make it easier for new developers to get started with the platform. The project has been pretty popular and I am keen to see it continue to grow.

Right now Acire has a good feature-set to browse and run snippets, but I would love to see it continue to develop and include the following:

  • Dependency Checking – when running a snippet that requires a module that you don’t have installed, Acire should tell you and provide a one-click installation of the required module(s). Ed has a branch that he started, and this seems like a good start on this solution.
  • Async Documentation Checking – right now when Acire loads documentation links it stalls due to it’s non-async loading of the docs URL title. This causes significant problems if you are not connected to a network. It would be good to use GIO to solve this.
  • Better Searchability Of Snippets – I would love to see (a) a search box to do a text search across all snippets and (b) see a better taxonomy of snippets. There are two cases here: (1) I want a snippet that is part of a specific module, and (2) I want a snippet to help me with something (such as playing music). Today you can only search by category (which is mainly categorized by module name). This could be greatly improved.
  • Multiple Language Support – while I love Python, I would love Acire to be able to support multiple languages. I think the most elegant way to do this is to have a language pack for each supported language. Today you get Python content with the python-snippets package, but I would love to see c#-snippets as an example.

Would you like to take the reigns with Acire? If so, drop me an email to jono AT ubuntu DOT com.

Python Snippets

For Python Snippets I would like to grow a team of reviewers. Right now I approve all merge proposals and merge them into the branch (which is used to generate the daily PPA), but I think it makes better sense to distribute this work across a number of contributors that can communicate via a mailing list.

If you are interested in joining this team, drop me an email to jono AT ubuntu DOT com.

PyJunior

PyJunior was a project I wrote in a few hours while on vacation. The whole point is to make programming for kids much easier, and although simple, the program is off to a good start.

PyJunior really excites me. It holds so much potential to really introduce kids to Python and all the fun you can have with it. Some plans I have had for PyJunior include

  • Integrated Kid Friendly Docs – I have a dream for the documentation in PyJunior. You click the Help button and a window displays a list of Recipes. These are tutorial documents that outline how to do something fun such as make a calculator or a game. Each recipe not only explains how to write the code in simple kid-friendly steps, but also includes a button next to each code snippet that will paste it into the editor. I think it could be awesome to have a PyJunior Docs Team that produces these docs, and that the Recipe Browser would grab them off the Internet to save having to ship them with the app. This could really open up the world of programming for kids.
  • Sharing Programs – I includes a Share button in PyJunior that is switched off by default, but the goal was to create one-click way in which you can share a program with your friend. Kids need to be able to easily help each other with programs and this would provide a means for one kid to share his/her program with their friend who can then help them do something or fix a problem.
  • Interactive Tutorial – I would love to have written an animated interactive tutorial (like the first level of a modern game that explains how the controls work) that explains how the interface works.

Would you like to take the reigns with PyJunior? If so, drop me an email to jono AT ubuntu DOT com.

Moving On

If any of these projects sound exciting to you, do get in touch. I want to make sure that each has a competent maintainer who has the time to commit to the project, so I will go through a short evaluation for each. Thanks in advance to everyone who volunteers to help. :-)

Read more
jono

While I have been away this week on vacation there were 16 new submissions with new snippets! I utterly flabbergasted at how many of you good folks are contributing snippets.

I just reviewed all of these submissions and we now have a bunch of new snippets, including:

  • WebKit examples and a fantastic snippet for theming a table dynamically.
  • Handling CSV files.
  • A slew of new DesktopCouch snippets.
  • A bunch of new Clutter snippets.
  • A snippet that reads in OpenOffice.org spreadsheets (.ods files).
  • We also had some new categories started with new snippets for the inspect and gconf modules.

Thanks everyone for your rocking work! We now have 191 snippets in the library! :-)

Want to contribute? Go and find out how!

Read more
jono

Just a quick note: the PyJunior code is up on Launchpad. Please remember: I wrote this in about two hours and haven’t had any time to clean it up. So, expect warts and all. :-)

The Open Sourcerer pointed me at Snake Wrangling for Kids as a great kid-friendly guide for learning Python. My dream now is that when a kid clicks the big Help button in PyJunior, that the book pops up in native GNOME help format. Problem is: I have absolutely no idea how to convert Snake Wrangling for Kids (which is available in LaTeX and PDF format) into this help format, and don’t really have any time to contribute to this either.

So, I am looking for help. PyJunior provides a simple and effective of way of playing with Python for kids, but we really need the documentation to make this story rock. Is there anyone out there who would like to work on this and make clicking that Help button a fantastic experience for kids interested in learning programming? I really hope so: this could be a wonderful learning tool for ankle-biters everywhere. :-)

If you are interested in helping, do let me know in the comments on this blog entry and we can talk more. If you just want to crack on and make the docs love happen, do feel free to go ahead and submit a merge proposal when you have something.

To do those who help, thanks so much in advance! :-)

Read more
jono

This week I am in Mexico on vacation with my wife and it has been wonderful getting out and about, catching some rays and and chillin’ by the pool. Mexico is a wonderful place and the people here are just incredible. It has been a wonderful week.

Yesterday I had a break from the sun and a few hours spare and wrote a little program I have been wanting to write for a while. First though, a little back story.

A little while back, Aq and I did a Shot Of Jaq shot about how back in the good ol’ days computers used to make programming more accessible to kids. The basic gist of the shot was that when you bought a Commodore 64 or Spectrum, access to the BASIC language was up-front, and your computer came with a manual that taught you how to write programs in BASIC. This was great for kids and others who wanted to explore their computers. It introduced them to programming, and taught them that you could make the computer do all manner of different things if you learned this simple language, while all the time teaching them about logic and semantics. This was an incredible thrill for me when I was such an ankle-biter: I felt this tremendous liberation that I could write any kind of program I wanted. In a nutshell, it sowed the seeds of opportunistic development in my mind.

The Shot Of Jaq shot really got me thinking about how accessible to programming computers are for kids today. I did a quick scoot around to research what software was available, and there seemed to be limited options that would be suitable for young kids. As such, I decided that this could be a fun little project for me blow a few hours of free time on. And thus…PyJunior was born.

PyJunior is a little program that has a very focused goal: to provide a simple environment for kids to play with Python. Python is a beautiful language and one ideally suited for kids and others to get started with programming. My goal was to make something incredibly simple and very focused on simple programming tasks. My intention here is not to build a full programming environment with access to Glade, PyGTK documentation and testing tools: that is simply too much. It was instead to allow a kid to write instructions in a program, press a button and watch it work.

As part of focusing my design on simplicity, I had a few core concepts in mind when writing PyJunior:

  • No complex projects – multi-file projects are confusing and beyond the scope of PyJunior. The focus here is on single programs.
  • No saving – I don’t want kids to have to think about saving when writing their programs. They should focus on writing code and running it, not remembering to save.
  • No concept of files – when learning about programming, each unnecessary step is likely to confuse them and lose their interest. They should not need to think about creating a .py file and executing it, and instead just have the concept of creating and loading programs.
  • Lean user interface – too many buttons and menus are likely to confuse the user, so the interface needs to be lean and focused on it’s core functions.
  • Kid-friendly user interface – kids that are young are new to using mice, so the buttons need to be nice and big and clickable. The buttons also need to be discoverable: we can’t assume they know what the icons mean, so they need to be labeled.

Let me show how it works. This is the main interface:

The interface is simple. There is an area where you can type in code in at the top (which is syntax highlighted to make it easier to understand), and below it is where the output of the program is displayed. At the top is a toolbar that I have deliberately made nice and big and easy to click for kids who are new to using a mouse. When they want to run the code they have typed in, they click the Run button. This will automatically save the file, run it and display the output in the black area at the bottom.

The interface makes teaching kids how to write programs easy: they write in the instructions, press the Run button and see the results of their instructions in the black area at the bottom.

If the user wants to create or load a new program, they click on the My Programs button and see this:

In designing PyJunior, I was conscious to make a one stop shop for dealing with new and existing programs: I didn’t want to have separate dialog boxes for new and existing programs as I felt his would clutter the interface (I want to keep that toolbar lean) and confuse the user. I was also really keen to not simply use a file picker for creating and loading programs: kids are likely to get confused by it and pick the wrong files, accidentally delete things etc. As such, I decided to put the program creation and loading in one dialog, and make it as simple as possible.

To create a new program, I wanted to make it as simple as typing in a descriptive name for the program as opposed to a filename. When the user types this in, PyJunior creates the file and immediately loads it in the main editor as shown above. This will also add the program to the list of existing program that can be loaded (shown at the bottom of the My Programs dialog box). To load a program, a list of already created programs in shown and the user can double-click it to load it in the editor. This entire process entirely bypasses the concept of files and directories: the focus is on descriptive names that refer to progams as opposed to filenames.

…and that is pretty much it. I am pretty pleased with my few hours of hacking, and I think it provides a good base for future development. I am still on vacation so there is no code uploaded or packages built yet, but I will have this arranged soon. Before I wrap up though, I want to talk about one more thing which is critical to the success of PyJunior: the Help button.

I feel PyJunior provides a great way of getting kids started with working with programs, but it doesn’t help them learn Python. What we really need now is a simple set of documentation that teaches kids in a very kid-friendly way how Python works. I would ideally like the user to click on the nice big Help toolbar button and it shows a standard GNOME help window with a tutorial about how to use Python. This documentation needs to be written and designed for kids: it needs to be visual and easy to read, and explain core elements of Python such as variables, lists, dictionaries, input, conditional statements and loops. So this is where I would like to focus the next steps of PyJunior, but I really need help with this: would anyone be interested in helping?

Read more
jono

Today Andy Breiner submitted a new Python snippet that demonstrates the use of the os module and Regular Expressions and looks at all the snippets in the Python Snippets library and counts how many people have submitted snippets. This is a great way of seeing how many people are contributing to the project. Well, I wanted to share the date with you folks:

  • Jim Bublitz: 15 snippets
  • Andy Breiner: 11 snippets
  • Jono Bacon: 10 snippets
  • Darren Worrall: 7 snippets
  • Simon Vermeersch: 6 snippets
  • Scott Ferguson: 4 snippets
  • Jurjen Stellingwerff: 4 snippets
  • Tim Voet: 3 snippets
  • Markus Korn: 3 snippets
  • Siegfried-Angel Gevatter Pujals: 3 snippets
  • Huntly Cameron: 3 snippets
  • Tiago Boldt Sousa: 2 snippets
  • Simon Edwards: 1 snippet
  • Scott James Remnant: 1 snippet
  • Benjamin Klueglein: 1 snippet
  • Rich Jones: 1 snippet
  • Oliver Marks: 1 snippet
  • John Turek: 1 snippet
  • Jonathan Riddell: 1 snippet
  • Josh Holland: 1 snippet
  • João Pinto: 1 snippet
  • Gonzalo Núñez: 1 snippet
  • Nick Veitch: 1 snippet
  • Evan Briones: 1 snippet
  • David D. Lowe: 1 snippet
  • Bruno Girin: 1 snippet
  • David Futcher: 1 snippet
  • Bastian Kennel: 1 snippet
  • Andre “Osku” Schmidt: 1 snippet

What a fantastic collection of top-tier rock stars! These people have come together to contribute to a total of 173 snippets as it stands today! The other snippets in the library don’t have a specific author attached (they came from documentation).

I am not only pleased with how some of these folks have really gone to town in creating snippets, but also just how many different people have contributed. That is fantastic.

Of course, you can be one of these people too! Go and find out how to contribute your Python snippets today!

Read more
jono

I am proud to announce the release of Acire 0.4!

This release includes the following new features

  • Documentation Links – many snippets now include links to relavent documentation links, and these are shown right within the Acire interface and just a click away.
  • Alphabetized Lists – the list of categories in Acire and the list of snippets in each category has now been alphabetized which makes navigating available snippets much easier.
  • HIG improvements – thanks to Matthew Pirocchi fo contributing a branch for helping Acire to fit in with the GNOME HIG better. The changes are subtle but really sleek. :-)
  • Number of snippets – the number of snippets that are currently available are now shown on the status bar.
  • Link to how to add snippets – Acire is nothing without python-snippets, so I added a link in the Help menu to this page which explains how people can contribute snippets.

These features are in addition these features which already exist:

  • Diverse Library Of Examples – via the Python Snippets library, Acire provides you with access to hundreds of available snippets spanning a wide variety of Python modules.
  • New Snippets, Daily – for Ubuntu users, our library of Python Snippets is available in a package that is updated daily. We are always adding snippets, and they will be delivered to your system effortlessly.
  • Browse Snippets Easily – snippets are organized into a series of categories which neatly map to Python modules. When you select a category you will see a list of available snippets.
  • View Code – code for snippets is just a click away, using full syntax highlighting and respecting your Monospace font settings on your desktop.
  • Test and Run Snippets – snippets can be run right from Acire with a single click. See a snippet running, browse the code and understand how it works.
  • Play With Snippets Your Way – looking at a snippet’s code and want to change something to see what happens? No problem, edit the code, run it and have fun. When you are done you can even save your snippet to a file on your computer.
  • Available In Your LanguageAcire is available in multiple languages, with many more with each release.

Installing Acire 0.4 is a doddle if you are running Ubuntu (Lucid and Karmic) or Debian, just follow the instructions. Right now Acire is not packaged for other distributions, but I would love it to be: drop me a line if it is and I will update the website with installation details.

At the heart of the Acire and Python Snippets project are Python snippets that are contibuted by the community. We need YOUR help to produce more snippets to help opportunistic developers really harness our wonderful platform. To contribute a snippet follow the guidelines here.

Read more
jono

With the goal of Acire and Python Snippets seeking to serve multiple distributions, it seemed appropriate to give it it’s own website. Thanks to the wonderful people over at wordpress.com for making my fave CMS available as a free hosted service, we now have our new website!

This was a result of a few hours work, so there is plenty to do on the site. Let me know what kind of content you would like to see.

Of course, the most important page is the how to contribute a snippet page if you…er…get my drift. ;-)

Read more
jono

I just wanted to share something I am rather proud of. Python Snippets, the project I put together to gather an archive of simple Python examples that can be viewed with Acire on your desktop.

Well, today I merged in our 150th snippet, contributed by Andy Breiner. For the curious, the record-breaking snippet demonstrates how to delete a record from a CouchDB database with DesktopCouch.

We now have 150 simple Python examples that span 20 different areas:

  • Application Indicator – application indicator examples.
  • Apport – the apport crash handling framework.
  • bzrlib – bazaar source control system Python module.
  • Clutter – clutter toolkit examples.
  • dbus – dbus messaging system
  • DesktopCouch – desktopcouch examples.
  • feedparser – parsing RSS feeds.
  • Gstreamer – python-gstreamer examples.
  • Gwibber – gwibber microblogging tool
  • Notify OSD – notify OSD examples.
  • PyGTK – pygtk widget and framework examples.
  • PyGTKSourceView – pygtksourceview widget and framework examples.
  • Python Core – examples that demonstrate core features in the Python language.
  • Python VTE – snippets using the VTE widget for GTK.
  • PyKDE4 – KDE Python bindings.
  • PyQt4 – Qt widget examples
  • Patterns – design pattern examples.
  • launchpadlib – examples using launchpadlib.
  • WebKit examples uing the webkit browser widget.
  • Zeitgeist – examples on how to use Zeitgeist.

I am really pleased how Acire and Python Snippets are becoming a constantly growing resource that is actively helping developers get to grips with different modules. Thanks to everyone who has contributed snippets to the library!

Of course, we want more snippets, so if you want to add some, go and read this guide to explain how!

Read more
jono

Recently I asked for some help on how to download a file without blocking the GUI. Thanks to everyone who contributed their expertise in the post comments: I now have my program working great.

I wanted to now share my conclusions so that others can benefit from them too. To do this I am going to first explain how this works, and secondly I have created a Python Snippet and added it to the Python Snippets library so there is a great working example you folks can play with. You can use Acire to load the snippet and play with it. This is the first gio snippet, and I hope there will be many more. :-)

The goal I set out with was to download a file without freezing the GUI. This was somewhat inspired from a recent Shot Of Jaq shot that we did on async programming, and I used this app as a good example to play with. Typically I had downloaded files the manual way and this had blocked my GUI hard, but I was aware that this is exactly what gio, part of the GNOME platform is here to solve.

The way async basically works is that you kick off an operation and then you wait for confirmation of the result before you proceed. It is the opposite of procedural programming: you don’t kick off an operation and in the next line process it. When you do things the async way, you start an operation and then tell it what callback should be called when it is complete. It feels very event-driven: kind of how you connect a handler to a signal in a widget so that when that signal is generated, the handler is called.

When I started playing with this the docs insinuated that read_async() and read_finish() were what I needed to use. I started off with code that looked a little like this:

def download_latest_shot(self):
    audiourl = "http://....the url to the Ogg file...."

    self.shot_stream = gio.File(audiourl)
    self.shot_stream.read_async(self.download_latest_shot_complete)

It then calls this callback:

def download_latest_shot_complete(self, gdaemonfile, result):
    f = self.shot_stream.read_finish(result).read()

    outputfile = open("/home/jono/Desktop/shot.ogg","w")
    outputfile.writelines(f)

After some helpful notes from the GNOME community, it turned out that what I really needed to use was load_contents_async() to download the full content of the file (read_async() merely kicks off a read operation) and load_contents_finish() as the callback that is called when it is complete. This worked great for me.

As such, here is the snippet which I have added to the Python Snippets library which downloads the Ubuntu HTML index page, shows it in a GUI without blocking it and writes it to the disk:

#!/usr/bin/env python
#
# [SNIPPET_NAME: Download a file asynchronously]
# [SNIPPET_CATEGORIES: GIO]
# [SNIPPET_DESCRIPTION: Download a file async (useful for not blocking the GUI)]
# [SNIPPET_AUTHOR: Jono Bacon <jono@ubuntu.com>]
# [SNIPPET_LICENSE: GPL]

import gio, gtk, os

# Downloading a file in an async way is a great way of not blocking a GUI. This snippet will show a simple GUI and
# download the main HTML file from ubuntu.com without blocking the GUI. You will see the dialog appear with no content
# and when the content has downloaded, the GUI will be refreshed. This snippet also writes the content to the home
# directory as pythonsnippetexample-ubuntuwebsite.html.

# To download in an async way you kick off the download and when it is complete, another callback is called to process
# it (namely, display it in the window and write it to the disk). This separation means you can download large files and
# not block the GUI if needed. 

class Example(object):
    def download_file(self, data, url):
        """Download the file using gio"""

        # create a gio stream and download the URL passed to the method
        self.stream = gio.File(url)

        # there are two methods of downloading content: load_contents_async and read_async. Here we use load_contents_async as it
        # downloads the full contents of the file, which is what we want. We pass it a method to be called when the download has
        # complete: in this case, self.download_file_complete
        self.stream.load_contents_async(self.download_file_complete)

    def download_file_complete(self, gdaemonfile, result):
        """Method called after the file has downloaded"""

        # the result from the download is actually a tuple with three elements. The first element is the actual content
        # so let's grab that
        content = self.stream.load_contents_finish(result)[0]

        # update the label with the content
        label.set_text(content)

        # let's now save the content to the user's home directory
        outputfile = open(os.path.expanduser('~') + "/pythonsnippetexample-ubuntuwebsite.html","w")
        outputfile.write(content)

ex = Example()

dial = gtk.Dialog()
label = gtk.Label()
dial.action_area.pack_start(label)
label.show_all()
label.connect('realize', ex.download_file, "http://www.ubuntu.com")
dial.run()

I am still pretty new to this, and I am sure there is plenty that can be improved in the snippet, so feel free submit a merge request if you would like to improve it. Hope this helps!

Read more
jono

As many of you will be aware, this week Ubuntu Opportunistic Developer Week took part, and the week has been wonderful so far. There has been so much excitement and interest, and I have been tickled pink at just how many people have been telling me that the week has re-invigorated their interest or given them a new passion for writing fun and useful apps. Ubuntu is an awesome platform for making these apps, and it has been a real pleasure to see people getting so fired up about using it. :-)

Before the week kicked off, I offered a fun little challenge called The Grand App Writing Challenge. With a week of rocking content ahead designed to help build a fun and thriving community who like to write apps that scratch their itches, I put forward the challenge for you good people to write some apps and see how far you get this week, and I will blog your progress at the end of the week. Well, while we still have a few sessions yet to go, it is Friday and I was keen to show off some progress!

With which, I present the wonderful submissions from some of our attendees this week!

HardwareMap

Chris Couzens wrote in and shared his project HardwareMap:

My program is called HardwareMap. It lists computers and services on the local network (Avahi) and hardware connected to your computer (HAL). When you click a device, it tells you properties of the device and lets you perform common actions for that device. For example, an ftp share has a button to open in Nautilus, a webcam has a button to open in Cheese and an inline preview of the webcam.

More Info

Blogite

Andy Breiner writes in about Blogite

I created a python program called Blogite. It is suppose to be similar to Gwibber but for RSS feeds. It pulls in the RSS feeds, but I need a better way of displaying the feeds. I want to add categories so rss feeds can be easily separated and shown. It is still slightly rough around the edges. I also want to add pictures so it can show the picture right next to the post similar to Gwibber.

Fantastic! This looks like it has bags of potential!

More Info

Rename Them All

Owais Lone wrote in to share an application which can be described pretty easily:

A simple Batch Renamer; That’s it. Even having a screenshot of my app on jono@home would be something I’ll cheer about for a couple of months at least.

Consider it done, Owais. :-)

Owais made great progress this week, so check out the project!

More Info

sshsplit

Martin Eve writes in with his first app, in the form of sshsplit:

I recently saw your Great App Writing contest post and decided, over the weekend, to knock something up. This is my first effort at using Python, having previously had quite a lot of experience in C# and .NET. My program is called sshsplit. It multiplexes ssh dynamic tunnels. An example perhaps serves better. Normally you would: ssh -D 54321 remote-host – to get a tunnel on 127.0.0.1:54321 that goes through remote-host. However, if you are using a network-resource-intensive application (torrent clients for example), this single tunnel will not suffice for, say, 1000 concurrent connections. sshsplit launches several instances of the ssh dynamic tunnel and then load balances between them. If no arguments are passed, sshsplit launches the configuration GUI. Otherwise, for help, run: sshsplit -h. sshsplit can also be configured to use any binary you would like

Great work, Martin! It looks like you made fantastic progress!

More Info

Uninstaller for Adobe® AIR® 1.0.0

Bernard Opic writes in with his very first app too:

Uninstaller for Adobe AIR is an easy solution for uninstalling Adobe AIR applications. When installing an AIR application it is possible to first save the installation program file (. air). This file will then allow to install but also to uninstall the application, provided that the AIR engine is installed and functional. If you install an AIR application from its source without saving its installation program file, or if the AIR engine is not available, uninstalling an AIR application can be difficult on a GNU/Linux system because it requires the use of system commands via a shell. Thanks to Uninstaller for Adobe AIR it becomes very easy to uninstall an AIR application since it suffices to choose it from a list of installed applications and click on an Uninstall button. Uninstaller for Adobe AIR is a free software under GPL version 3 license, designed to compatible with the GNU/Linux Ubuntu distribution and with the GNOME and KDE window managers.

Great work, Bernard!

More Info

Splatter

Anirudh writes in with another fun and useful app in the form of *Splatter:

I’m an (opportunistic :) ) student developer, and wanted a better way to collaborate on bugs and watch issues on some of my favorite projects. However I hated having to go through bugzilla’s overwhelmingly complex interface just to check up for new comments and changes. If I turned on email notification I’d be hit with a barrage of emails which I’m not too fond of. I felt it was time for things to change. So over the past one and a half weeks, I wrote Splatter – a gnome app to keep track of bugs. It evolved from a very simple concept of being a frontend to a bugtracker to becoming a tool for collaboration on tasks with fellow developers.

Great work, Anirudh!

More Info

Ain’t Easy Project/Goal Manager

Andrew Sellers shares with us his work on Ain’t Easy:

For those of us currently deluged with work, stretching from one week to another, or simply those who work on many different things, tracking down when an event is happening in nigh impossible. Not just that, sometimes goals will simply get buried under a mass of other projects. It just ain’t easy to keep up with all of it. Some things aren’t fit for a calendar, while others just don’t work well with to-do lists. Finally sometimes you have to associate text or documents with an event, how are you going to do that? That’s where Ain’t Easy comes in. Straight from Alabama, this application will take as many goals or projects as you can throw at it, throw your links and text at it, it’ll just save it and let you launch it a simple double-click of the mouse.

I look forward to seeing more updates, Andrew!

More Info

The Results

In my original blog post I offered to send three of the projects an Ubuntu t-shirt. I was going to pick three fave projects, but I think all the submissions are great, so I going to send you all a t-shirt. Thanks all for taking part!

Read more
jono

A user called Eric left a comment on my Ubuntu Opportunistic Developer Week and Python Snippets Day blog entry which I felt really needs highlighting:

Thank you and the entire Canonical team for putting the Opportunistic Developer Week together!

I’ve been stuck doing heavy, back end enterprise Java programming for the past few years. My interest in programming slowly fizzled out.

On a whim, I decided to check out quickly, acire and the learning materials your team put together. PyGTK erased all the bad taste in my mouth from the Swing applications I’ve coded. :-) I haven’t had this much fun programming in a long time! Thanks so much!

This is exactly what I want us to do as community, to help unlock creativity in people’s minds and lower the barrier between idea and implementation. Thanks, Eric, you really put a smile on my face with that one.

Read more
jono

Ubuntu Opportunistic Developer Week day 4 kicks off and we have some incredible events today:

  • 5pm UTC – Hot rodding your app for translations support – David Planella
  • 6pm UTC – Learning through examples with Acire and Python-Snippets – Jono Bacon
  • 7pm UTC – Write Beautiful Code (and Maintain it Beautifully) – rockstar
  • 8pm UTC – Speed your development with quickly.widgets – Rick Spencer
  • 9pm UTC onwards – Snippets Party – Join us in #ubuntu-app-devel and create Python snippets to share with other people – see this page for details of how to get involved!

It is recommended that you enjoy the week in Lernid. You can find out more details of how to install Lernid right here. Don’t want to use Lernid? No worries, just pop over to #ubuntu-classroom and #ubuntu-classroom-chat to join in the fun. Don’t forget that #ubuntu-app-devel is the place to ask questions about general development on Ubuntu. :-)

Join the snippets party!

Today is a special day this week: in addition to providing some great content to help people get started writing apps on Ubuntu, we are also keen to continue growing our wonderful library of python-snippets which is viewed with a program I wrote called Acire. This library of snippets provides a range of examples that you can run, play with, modify and merge into your programs. So many of us learn by doing, and the more snippets we have the easier it is the learn from a diverse range of topics!

We have two events today I am keen to encourage you to join. First I will be delivering a session on the python snippets project:

  • 6pm UTC – Learning through examples with Acire and Python-Snippets – Jono Bacon

In the session I will explain how the project came about, it’s current progress and where we are going. We will then have a fun snippets party a little later:

  • 9pm UTC onwards – Snippets Party – Join us in #ubuntu-app-devel and create Python snippets to share with other people – see this page for details of how to get involved!

The snippets party is simple: just join #ubuntu-app-devel on freenode and join us to write a bunch of snippets and contribute them to python-snippets. Today we have 104 snippets already in the library: I would love to see us get that to over 150 today. Come and join us!

Contributing snippets is simple: just click here to find out more!

Read more
jono

Just a quick note to let you all know that Ubuntu Opportunistic Developer Week day 3 kicks off in an hour!

Here is the order of events for today:

  • 5pm UTC – Creating stunning interfaces with Cairo – Laszlo Pandy
  • 6pm UTC – What’s new in Quickly 0.4 – Didier Roche
  • 7pm UTC – Create games with PyGame – Rick Spencer
  • 8pm UTC – SHOWCASE: Photobomb – Rick Spencer
  • 9pm UTC onwards – Hacking party in #ubuntu-app-devel on freenode! Come and join us, work on your apps, ask questions and have fun in our community. :-)

It is recommended that you enjoy the week in Lernid. You can find out more details of how to install Lernid right here. Don’t want to use Lernid? No worries, just pop over to #ubuntu-classroom and #ubuntu-classroom-chat to join in the fun. Don’t forget that #ubuntu-app-devel is the place to ask questions about general development on Ubuntu. :-)

Read more
jono

Just a quick note to let you all know that Ubuntu Opportunistic Developer Week day 2 kicks off in an hour!

Here is the order of events for today:

  • 4pm UTC – Gooey Graphics with GooCanvas – Rick Spencer
  • 5pm UTC – Writing a Rhythmbox plug-in – Stuart Langridge
  • 6pm UTC – Microblog from your app with the Gwibber API – Ken VanDine
  • 7pm UTC – SHOWCASE: Gwibber – Ken Vandine
  • 8pm UTC – Building multimedia into your app with GStreamer – Laszlo Pandy
  • 9pm UTC onwards – Hacking parts in #ubuntu-app-devel on freenode! Come and join us, work on your apps, ask questions and have fun in our community. :-)

It is recommended that you enjoy the week in Lernid. You can find out more details of how to install Lernid right here. Don’t want to use Lernid? No worries, just pop over to #ubuntu-classroom and #ubuntu-classroom-chat to join in the fun. Don’t forget that #ubuntu-app-devel is the place to ask questions about general development on Ubuntu. :-)

Read more
jono

Just a quick note to let you all know that Ubuntu Opportunistic Developer Week kicks off in an hour!

Here is the order of events for today:

  • 4pm UTC – Welcome! Ubuntu For Opportunistic Developers – Jono Bacon
  • 5pm UTC – CouchDB support in your app with DesktopCouch – Stuart Langridge
  • 6pm UTC – Creating an application from scratch with Quickly – Rick Spencer
  • 7pm UTC – Building in Application Indicator support – Sense Hofstede
  • 8pm UTC – Integrated development workflow with Ground Control – Martin Owens
  • 9pm UTC onwards – Hacking parts in #ubuntu-app-devel on freenode! Come and join us, work on your apps, ask questions and have fun in our community. :-)

It is recommended that you enjoy the week in Lernid. You can find out more details of how to install Lernid right here. Don’t want to use Lernid? No worries, just pop over to #ubuntu-classroom and #ubuntu-classroom-chat to join in the fun.

Read more
jono

Well, folks, this week Ubuntu Opportunistic Developer Week kicks off with a fantastic week jammed with great sessions helping to bridge the gap for opportunistic developers who want to write fun, useful applications using Ubuntu as a platform. We have a wonderful week of sessions ahead and as ever, it is recommended that you enjoy the week in Lernid. You can find out more details of how to install Lernid right here. Don’t want to use Lernid? No worries, just pop over to #ubuntu-classroom and #ubuntu-classroom-chat to join in the fun.

I will be kicking off the week at 4pm UTC and talking through the goals for the week and talking through some of the work we are doing to help opportunistic developers enjoy Ubuntu as a platform and write some fun apps.

Friends, also don’t forget about the fun challenge I set last week:

Think of a fun program to write, and see how much you can get completed by the end of the week, Fri 5th March 2010. On Friday I will write a blog entry that showcases screenshots of your progress and (if possible) a PPA where people can download a package to try.

When you have something you would like me to blog, send an email no later than the end of the day Pacific time on Thu 4th March 2010 to me at jono AT ubuntu DOT com and include:

  • The name of your program and a brief description of what it does.
  • A link to a screenshot online that shows your new app running.
  • If available, tell me the name of the Launchpad project where it is hosted and the PPA with the package. This is a great way for people to try your program and possibly join the project and contribute to it!

I will send a t-shirt out to the three app authors who made the most interesting apps with the most progress. :-)

Start your engines folks, let’s see what we can do! I can’t wait to see how you folks get on! :-)

Read more
jono

With the new release of Acire just out I wanted to tell you folks a fun little story of an added benefit to Acire that I never envisaged when I came up with the idea for the app.

Yesterday I got an email from someone (I will keep the identify private) saying:

I’m trying to create an application but I can’t seem to find any way to embed a gnome-terminal into my app. I know you’re not offering support :) but if you have some spare time is there any chance you can point me to the documentation for that?

This happens a lot: someone wants to do something, so they ask for help over email or on another medium such as IRC. Unfortunately, I am usually pretty busy and typically don’t have the time to answer support questions. Before Acire existed I would have at most hunted out some links or possibly just the person to to go and ask on a particular forum or mailing list.

Now Acire exists, I just fired it up, selected Python VTE from the cateogries combo box, clicked on the snippet, and then cut and pasted the code into the email:

#!/usr/bin/env python

# [SNIPPET_NAME: Embed a VTE terminal]
# [SNIPPET_CATEGORIES: Python VTE]
# [SNIPPET_DESCRIPTION: Embed a VTE terminal in your application]

try:
    import gtk
except:
    print >> sys.stderr, "You need to install the python gtk bindings"
    sys.exit(1)

# import vte
try:
    import vte
except:
    error = gtk.MessageDialog (None, gtk.DIALOG_MODAL, gtk.MESSAGE_ERROR, gtk.BUTTONS_OK,
        'You need to install python bindings for libvte')
    error.run()
    sys.exit (1)

if __name__ == '__main__':
    # create the terminal
    v = vte.Terminal()
    v.connect ("child-exited", lambda term: gtk.main_quit())

    # fork_command() will run a command, in this case it shows a prompt
    v.fork_command()

    # create a window and add the VTE
    window = gtk.Window()
    window.add(v)
    window.connect('delete-event', lambda window, event: gtk.main_quit())

    # you need to show the VTE
    window.show_all()

    # Finally, run the application
    gtk.main()

Job done. What made me smile about this was that Acire not only helps me, but it helped me help someone else too. Rocking. :-)

Read more
jono

Everyone’s favorite tool to browse Python snippets, run them, learn from them and incorporate them into your programs has been released! This new release has the following new features:

  • Translated – Acire has now got support for multiple languages, but this is very new so it needs your translations! Want to help make Acire rocking in your language? Easy. Go and contribute here!
  • Edit Snippets – Acire now allows you to edit the code inside a snippet and execute it within Acire itself.
  • Save Snippets – You can now save the snippets, even if they have been edited, into a specific file on your system.
  • Look and Feel Polish – a little bit of spit and shine has been applied to respect your chosen monospace font, use a scalable icon for docky and a few other little changes.

As I have mentioned before, I the snippets that Acire shows and the Acire itself are in two separate packages (this means that others can write viewers to view the snippets on other environments).

Installing Acire and it’s snippets is simple. First install the daily snippets PPA (this will deliver new snippets to your system on a daily bases):

sudo add-apt-repository ppa:python-snippets-drivers/python-snippets-daily
sudo apt-get update
sudo apt-get install python-snippets

Now install the Acire PPA:

sudo add-apt-repository ppa:acire-team/acire-releases
sudo apt-get update
sudo apt-get install acire

Right now packages are available for Ubuntu 10.04 Lucid Lynx and Ubuntu 9.10 Karmic Koala packages should be available soon.

We need your snippets!

The fuel that makes Acire rock is the library of snippets. To really get the most out of Acire and it’s library of snippets, we need you to contribute snippets that demonstrate something in Python. These snippets are really helpful in showing us all how a given Python modules works, and really helpful in lowering the bar to development. Here is how you can contribute a snippet!

Step 1: Grab the library

Just run:

bzr branch lp:python-snippets

Step 2: Create your snippet

A snippet should demonstrate a specific feature in a given module or in the Python language. This could include showing how to use a specific widget, a feature of that widget, or another function.

python-snippets is divided into sub-directories which outlines the theme of the snippets. You should pick the most appropriate directory to put your snippet it, and add it there. If a suitable directory does not exist already, create it and add it there.

Step 3: Add metadata

The way Acire pulls out the snippets is by detecting some specific metadata additions to comments at the top of the file You should now add the following meta data as comments to the top of the file:

# [SNIPPET_NAME: A Short Name For The Snippet]
# [SNIPPET_CATEGORIES: Category]  <-- see CATEGORIES file for existing categories
# [SNIPPET_DESCRIPTION: A single line description of the snippet]
# [SNIPPET_AUTHOR: Your Name <your@emailaddress.com>]
# [SNIPPET_LICENSE: An Open Source license (from the LICENSES file)]

Here is an example:

# [SNIPPET_NAME: Playing a Pipeline]
# [SNIPPET_CATEGORIES: GStreamer]
# [SNIPPET_DESCRIPTION: Construct and play a pipeline]
# [SNIPPET_AUTHOR: Jono Bacon <jono@ubuntu.com>]
# [SNIPPET_LICENSE: GPL]

You now need to add your file to your branch with:

bzr add your-snippet.py

Step 4: Propose it for merging

With your new snippet ready, it is time to propose it for inclusion in the main python-snippets library.

First, commit your changes to your local branch with:

bzr commit

Now push it to your own branch on Launchpad:

bzr push lp:~<your launchpad username>/python-snippets/<name of your branch>

As an example:

bzr push lp:~jonobacon/python-snippets/gstreamer-snippets

Now go to https://code.launchpad.net/python-snippets and you should see your branch listed there. Click on it and when the branch page information page loads click on the Propose for merging link. Add a short description of what you examples do in the Initial Comment box and then click the Propose Merge button.

We will then review the merge and if it looks good, add it to python-snippets and it will be delivered to Acire users in the next daily package upload. :-)

Read more
jono

Yesterday I gave my talk on opportunistic developers on ustream.tv (which I plan on repeating next week). In that session I floated the idea of having a fun challenge next week when Ubuntu Opportunistic Developer Week happens. The idea was pretty popular, so I wanted to share it here.

The idea is simple:

Think of a fun program to write, and see how much you can get completed by the end of the week, Fri 5th March 2010. On Friday I will write a blog entry that showcases screenshots of your progress and (if possible) a PPA where people can download a package to try.

Getting Started

Getting started with this is simple. First think of something that would be fun to write. This could be a GUI front-end to a command line tool, a simple app that does something useful for you that will improve your life, a game or anything else. Pick something that isn’t too hard: something that is a good first step to dip your feet into development. Folks, do share ideas for apps in the comments here so those people who can’t think of something have a pool of ideas available. :-)

When you have idea you can create your app really easily with Quickly. You can first install Quickly from the Ubuntu Software Center by clicking Applications -> Ubuntu Software Center and search for quickly.

When it is installed, just run:

quickly create ubuntu-project <yourprojectname>

As an example:

quickly create ubuntu-project mycoolapp

Now run:

quickly tutorial

This will explain how to get started working on your application. If you have questions related to using quickly, you can join #quickly on freenode. If you have general software development questions, you can join #ubuntu-app-devel on freenode.

Sharing Your Progress

When you have something you would like me to blog, send an email no later than the end of the day Pacific time on Thu 4th March 2010 to me at jono AT ubuntu DOT com and include:

  • The name of your program and a brief description of what it does.
  • A link to a screenshot online that shows your new app running.
  • If available, tell me the name of the Launchpad project where it is hosted and the PPA with the package. This is a great way for people to try your program and possibly join the project and contribute to it!

I will send a t-shirt out to the three app authors who made the most interesting apps with the most progress. :-)

Start your engines folks, let’s see what we can do! I can’t wait to see how you folks get on! :-)

Read more