Oct 10, 2011

Datapkg-gui, first attempts with wxPython

Datapkg-gui, first attempt with wxPython

Time for a little update. It was quite hard to begin coding because I am not familiar with setuptools nor with wxPython.

As promised, I began writing the library wrapper for datapkg (it lives in /datapkggui/lib.py. I’m incrementally developing it, and add new functions as soon as I need them. At the current state, it supports downloading, searching and informing about packages. Of course those functions are not finished yet, but I am paying attention to documenting the code for future creations of the API.

For this project I am following Test-driven Development. Well, sort of. I don’t reach full coverage of the code written, because my functionalities are already tested by the under-the-hood engine datapkg. Tests live in /tests folder, and can be run using the command python setup.py nosetests (you need nosetests for running them). Surprisingly, I found that datapkg does not pass all its tests and not all the documented functions are fully working. Less work for me, that’s fine.

Well, let’s talk about the GUI. Here is a screenshot of the results of me playing with wxPython:

Datapkg-gui, first attempt with wxPython

It looks nice under KDE. I don’t know whether this is because of KDE/QT itself or because I am using a GTK style for GTK applications for KDE. Cool.

The bad news is that this is all I’ve done yet. The good news is that it works.

The constraint of using wxPython as GUI toolkit are a big issue for me. I’ve always developed GUIs using QT and I am spoiled by QTCreator, PyQT and QT themselves. It’s a pleasure to develop using those tools. wxPython are not exactly easy to be used, neither for GUI drawing nor for coding. Moreover, the library does not use really-to-be-remembered names. Anyway, I am happy with that, I’ve always wished I could find the time to learn another GUI toolkit. Now the time has come.

For sure the GUI will change over time, this is just me experimenting for know.

written by dgraziotin

Dr. Daniel Graziotin received his PhD in computer science, software engineering at the Free University of Bozen-Bolzano, Italy. His research interests include human aspects in empirical software engineering with psychological measurements, Web engineering, and open science. He researches, publishes, and reviews for venues in software engineering, human-computer interaction, and psychology. Daniel is the founder of the psychoempirical software engineering discipline and guidelines. He is associate editor at the Journal of Open Research Software, academic editor at the Research Ideas and Outcomes (RIO) journal, and academic editor at the Open Communications in Computer Science journal. He is the local coordinator of the Italian Open science local group for the Open Knowledge Foundation. He is a member of ACM, SIGSOFT, and IEEE.

Leave a comment