Category Archives: programming

Old django hack

Scenario: django 0.91 postgresql 9.1 psycopg1 bug when importing psycopg Fix: Edit django/core/db/backends/postgresql.py and import psycopg twice . try: .     import psycopg as Database . except AttributeError: .     import psycopg as Database

Posted in programming | Tagged | Leave a comment

Keep only the latest version of a package in cache

Hardcoded for ArchLinux, this python module prints out the files to remove if you want to keep only the latest version of a package in the cache directory: ./paclean.py|sudo xargs rm Source: http://code.google.com/p/fileversion-keeplast/

Posted in linux, programming, soft | Tagged , | Leave a comment

ImportError: No module named interface

OS=Ubuntu 9.10 Python version=2.6 After install a zope module using pip, for example z3c.password your zope installation gets broken. This is because pip have installed the module in /usr/local/lib/python2.6/dist-packages/zope and the original module zope.interface is in /usr/share/pyshared/zope/interface/ and has minor … Continue reading

Posted in programming | Tagged , | Leave a comment

jQuery ui datepicker + jQuery editInPlace

The goal of this post is to show how editInPlace plugin for jQuery can be used with the ui.jQuery.datepicker. Jacob Terry already made this very good but modifying Dave Hauenstein’s editInPlace plugin. Before show you the snippet here is the … Continue reading

Posted in programming | Tagged , , | Leave a comment

Consumo de ADSL por mail – ANTELDATA

cuentagigas.info es una interfaz simple para un bot(programa) que hace tiempo quería hacer para estar al tanto de cuántos gigas voy gastando en el adsl sin tener que estar entrando al sitio de anteldata, … si quieren probarlo: Detalles técnicos: … Continue reading

Posted in programming, soft | Tagged , , , , | 8 Comments

JSP Hello World Howto

This can be called a howto of “How can I make a hello world in JSP without unnecessary tools like, Eclipse, struts, servlets, JBoss, etc.?” only you, your text editor, tomcat and of course, your GNU-Linux box. 1. Create a … Continue reading

Posted in linux, programming, soft | Tagged , | Leave a comment

Python: using a module written in C

This is a brief tutorial for using a module written in C inside a Python program. It’s a summarized recipe fr those who want to run and test something fast without falling in reading the docs, but I recommend to … Continue reading

Posted in linux, programming | Tagged , | Leave a comment

Playing with python-rpy2

The goal was to prepare a little prototype to show the potential of R (r-cran) when used via its Python bridge python-rpy2, then show the results in a web application, for example, using django. In this example (in spanish) we … Continue reading

Posted in programming | Tagged , , , , , | 6 Comments

Python2.6 with mod_python in debian

As you may know, there are no packages yet for Python2.6 in debian or ubuntu. If you want to install it you can do it by hand and it will work perfectly (it did for me) Google a bit and … Continue reading

Posted in linux, programming, soft | Tagged , , , , | Leave a comment

ReSTlides.com: Online ReST based presentations

When asked by a friend to present Python for the web for an university course, I though: “Why don’t present Python inside some Python-powered slides?” and for training purposes I’ve created http://restlides.com/ a django-powered site that allows us to create … Continue reading

Posted in programming | Tagged , , | Leave a comment