Django: limiting querysets in admin forms

Let’s suppose you have two related types of objects in your Django app. Call them Object and SuperObject, related ManyToMany‘ly. And when you add/change SuperObject in Django admin, there’s all Objects available for selection. But you need to limit the choices, and limit dynamically (perhaps, depending on current user). Here’s quite straightforward but working technique.

Read more…

PostgreSQL on Gentoo: split ebuilds

Just a note for those who looks for info on Gentoo & PostgreSQL (like I did today):

  • yes, as you might be already suspecting, PostgreSQL has been split

  • [STRIKEOUT:yes, there’s a little howto] there was one. Just install dev-db/postgresql-base (if you don’t need server; also it’s a dep for lots of packages, for example, those with USE=”postgres”) or dev-db/postgresql-server (PostgreSQL server)


Got stable now, old-style packages are masked and will be removed.

A quest

Now I have a Linux-server with external IP at my (almost my) disposal. Python, Django, PostgreSQL, nginx… So I can do everything I want. All that I need now, is to decide what do I want (-:E Any suggestions for me to implement?

Hardingrock - Grimen (2007)

Хы

If one had learnt about the Stone of Scone, browsing pages about Discworld dwarf bread, just in several hours he would stumble across this Stone in Wikipedia, reading about a year from Heidevolk’s song title

Ӱлгер - Агын Хустар

High-level and low-level

Fresh impressions.

Low-level programming trap — writing for half of a day code instead of finding suitable ready-to-use module in five minutes.

High-level programming trap — looking for suitable module for a few hours instead of writing your own code in quarter of hour.

IMified

Now IMified works at last, so I can “spread the word” about it. But… it’s too late and I’m too lazy to type all that you can read on the off.site… (-;E

So go right there and find out how do you get notes, ToDos, reminders etc in your Jabber! (-:E

OpenSource warrior

I am great warrior of OpenSource, indeed. On Thu, Oct 18 Kubuntu and Xubuntu 7.10 were released and in that evening I’ve downloaded all eight .iso-images and put it out in local network for people who cannot download them by ourselves. And today I managed to re-upload two images to other server for Far East Ubuntu users (-%E

Веснянка - Ой, заграли музиченьки [2003]