Tuesday, August 17, 2010

Announcing Django Packages!

I'm part of a two person team that just launched that BETA site for http://djangopackages.com, a site that is designed to list all the Django Applications, Frameworks, and Packages created by the Django community. While there are already a few places to look for these things, it is quite easy to argue that they are challenging to navigate, don't give any hard metrics, or are woefully incomplete/unstable/closed. Our goal was to provide an attractive, easy-to-navigate, easy-to-add-data, stable site and share it with the world.

Also, this was our entry into Django Dash 2010, and was the culmination of a few days of brainstorming over paper, a lot of research, and two days of feverish coding/designing. The project was feature complete to our specifications at 5pm the second day, and the rest of the time was spent adding in UI tweaks, usability enhancements, and trying to deploy our creation.

Since then, we've cleaned up a the UI, improved the design, and got the site stable. The code is open source and on github, so fork and contribute!

Design Consideration: No 'Like' button or 'Rate my app' rating systems

We wanted hard metrics. So the package numbers are pulled from the repo sites such as Github, Bitbucket, and Google Code. Otherwise things get weighted funny. Sure, this system can be monkeyed with, but its a good metric for now. We've had suggestions from Django core developers of coming up with a quality check system, things like pypants and/or a formalized approval system.

Design Consideration: Grids

Early on we wanted to duplicate and improve upon the Django CMS Comparison page. There is also a version for Forums, but it would be nice to have a current one for blogs! In addition, recently I heard that 'tag clouds are the mullets of web 2.0'. This really struck a chord in my soul. Since we had metrics on packages, why not compare those metrics, and use those comparisons, which we call 'grids', instead of tags? In fact, we extended our idea and instead of traditional tabs we use grids in the top navigation area as seen below:


Design Consideration: Categories

The site groups packages into three categories, 'Apps' which are individual django applications. 'Frameworks' which are aggregates of apps and python modules. And 'Projects' which are implementations of Apps and Frameworks. We've thought about adding 'Tools' but weren't sure if there was anything that fit that concept, and we are leery about allowing regular Python efforts into the fold.

Design Consideration: Regex vs XML

Slurping data out of Github was easy, especially since I used python-github2. Bitbucket has a RESTful API as well that serves out JSON. I think Google Code does as well. PyPI does not and DOAP on PyPI seems to give little that is useful, so I was forced to do screen scrapes of version numbers and downloads. I'm much faster with Regex and string methods than XML juggling, and speed was of the issue this weekend. I'm not sure what benefit there is to redoing it in HTML5lib or lxml, since what I have works and appears to be stable.

Design Consideration: Leave caching and optimization for later

Besides a tiny bit of memory based template caching on the home page, there is/was no optimization. In time I plan to cache many things using a proper key/value store like redis or memcached. Perhaps not before more design and usability work is done.

Why scared of rabbits?

You wouldn't understand unless you live on the Kansas prairie.

Note: if you have any suggestions, issues, problems with Django Packages please use our issue tracker!

16 comments:

Mathieu Leduc-Hamel said...

Very cool initiative !

Do you think you'll implement a way to use your site with a kind of "find-link" mechanism ?

I would love to be able to use your website in my buildout confs ! ;0

pydanny said...

@arrakis - Open up a ticket and we'll consider it! github.com/pydanny/scaredofrabbits/issues

peterbe said...

I've got some django packages that I'd like to see included.

Perhaps that should be a top-priority design consideration: How to add more packages.

pydanny said...

@peterbe - Just go to http://djangopackages.com/packages/add/ and do it yourself.

We are trying to figure out how to make the links to that page more obvious. :P

akaihola said...

You've created the missing piece! With all the great reusable apps and tools, the problem – especially for new Django developers – has been how to find and evaluate them.

My thought with the CMS and forum app wiki pages always was that they really should evolve into a central app database, and it should be super easy for app developers and the whole community to contribute data. Such existing sites just weren't good enough. Django Packages already seems to be.

It's great that the code for your site is open as well. But let's not stop there: public dumps of the database and a comprehensive public API could inspire cool tools from the community.

Thanks, Daniel and Audrey!

Anonymous said...

Now you just need to add something so I can select packages x, y and z and it creates a new repository for me on bitbucket with a basic app layout using them ;)

peterbe said...

@pyDanny

You know how the "Add package" and "Add grid" appears only once you're logged in, I would make it always appear and then if you're not logged in it diverts you to sign up/log in.

Major feature request: Maturity and last update date on the packages is often key to decide sometimes which one to choose.

Anonymous said...

Regex vs XML?

michuk said...

Great initiative. I can see it grow big.

In projects tab (http://djangopackages.com/categories/projects/) you can add Filmaster, the open source film recommendation engine & community website powered by django.
Bitbucket: http://bitbucket.org/filmaster/filmaster-test/
Developer's website: http://filmaster.org
The actual website: http://filmaster.com

Bill Mill said...

You should add an option "mercurial" in the "Repo" field of the "add an app" form.

Byteflow has their own hg repo at http://hg.piranha.org.ua/byteflow/ , but I can't add the package without lying about where the code is hosted.

Plus it should be relatively easy to drag some information out of any hg repository? I'm guessing because hg is in python, not because I've ever actually done so.

Bill Mill said...

Also, for some reason I can't submit http://github.com/f4nt/django-yaba/ , I get a server error when I try. I'm trying to make a grid of all reasonable blog engines, since I've been making a list. Strangely enough, I've been doing it for NASA as well as you have :)

pydanny said...

@michuk - Filmaster looks awesome! As for adding it to the projects, we are relying on the community such as yourself. Go ahead and create an account (http://djangopackages.com/signup) and add Filmaster as a Package under the category of 'Project'.

pydanny said...

@akaihola - We're so honored you like our efforts, since your work inspired a lot of the details of the grid. We had in mind public dumps of data and a good API down the road.

pydanny said...

@bill mill - Yeah, we've seen people adding in custom URLs for packages. Its an existing issue. :P

ptone said...

Would be neat to see a link between this and another dash project : readthedocs

pydanny said...

@ptone - Check out add Read the Docs link!