Category Archives: Python

Clearing custom crop aspect ratios in Lightroom

Lightroom’s crop tool allows you to constrain the aspect ratio to a proportion of your choice, e.g. to 4:3, defaulting to the same aspect ratio as the original. The last 5 or so custom crop aspect ratios are saved, but … Continue reading

Posted in Mac, Photo, Python | Leave a comment

Just enough Weave

Note: I am keeping this code around for historical purposes, but it has not worked since Weave 1.0 RC2. I created this because Mozilla’s public sync servers were initially quite unreliable, but they have remedied the situation and performance problems … Continue reading

Posted in IT, Python | Tagged | 2 Comments

Inserting graphviz diagrams in a CVStrac wiki

CVStrac is an amazing productivity booster for any software development group. This simple tool, built around a SQLite database (indeed, by the author of SQLite) combines a bug-tracking database, a CVS browser and a wiki. The three components are fully … Continue reading

Posted in IT, Python | Tagged | Leave a comment

A Python driver for the Symbol CS 1504 bar code scanner

One of my cousins works for Symbol, the world’s largest bar code reader manufacturer. The fashionable action today is in RFID, but the humble bar code is relatively untapped at the consumer level. The unexpected success of Delicious Library shows … Continue reading

Posted in Mac, Python | Tagged | 16 Comments

A reader-writer lock for Python

Python offers a number of useful synchronization primitives in the threading and Queue modules. One that is missing, however, is a simple reader-writer lock (RWLock). A RWLock allows improved concurrency over a simple mutex, and is useful for objects that … Continue reading

Posted in Python | Tagged | Leave a comment

Threadframe module version 0.2

After a comments thread on a request in Wilfredo Sanchez’ blog, including valuable contributions by Bob Ippolito, I have updated my threadframe module to leverage new thread tracking functionality added in Python 2.3. The module now allows Python 2.3 users … Continue reading

Posted in Python | Tagged | Leave a comment

Threadframe: multithreaded stack frame extraction for Python

Note: threadframe is obsolete. Python 2.5 and later include a function sys._current_frames() that does the same thing. Threadframe is only useful for Python 2.2 through 2.4. Rationale I was encountering deadlocks in a multi-threaded CORBA server (implemented using omniORB). Debugging … Continue reading

Posted in Python | Tagged , | Leave a comment

The Temboz RSS aggregator

Contents Introduction Features History Screen shots Known bugs Credits Download Updates Post scriptum Introduction Temboz is a RSS aggregator. It is inspired by FeedOnFeeds (web-based personal aggregator), Google News (two column layout) and TiVo (thumbs up and down). I have … Continue reading

Posted in Python, Temboz, Web | Tagged , | Leave a comment

Data mining Outlook for fun and profit

For a few years now, I have owned the domain name majid.fm. Dot-fm stands for the Federated States of Micronesia, a micro-state in the Pacific Ocean, and they market their domain names to FM radio stations. Those are also my … Continue reading

Posted in Python | Tagged | Leave a comment

Debugging DCOracle2 applications

DCOracle2 is the Oracle interface module for Python I use most often. It is advertised as “beta”, but quite suitable for production use, aside from a few minor rough edges. There are a few others, most notably cx_oracle, but I … Continue reading

Posted in Python | Tagged | Leave a comment