/ Software / Python

Python Software

"The joy of coding Python should be in seeing short, concise, readable classes that express a lot of action in a small amount of clear code -- not in reams of trivial code that bores the reader to death." -- GvR

"Python is the second best programming language in the world. But the best has yet to be invented." -- Christian Tismer.

I am publishing here Python-related software; mostly written by me. Unless otherwise noted, all software is free for any use. Please, provide a reference to my name; don't blame me for anything. Copyrighted by Oleg Broytman and PhiloSoft Design.

Some pieces of software are not so free - they are protected by GNU GPL.

All bits are packed with GNU tar+ gz or bz2.

m_Lib library and programs: bookmarks_db, mimedecode.

Outdated code: extract_mime, netscape-history, bdftogd.
Network-related libraries and programs ... not much yet: Python socket servers.
Some miscellaneous staff: PyGreSQL example, comparison of 3 Python-for-DOS interpreters.

The piece of software would not work without other; download it as well. "Requires: nothing" means "requires only standard Python library", of course.
Does not strictly require, but good to have it anyway.
Even easier than "recommends".

m_lib - Broytman Library for Python

A collection of modules I've been writing for common tasks in my programs. (You can read why the name starts with m :)
Download: m_lib.tar.bz2
git clone
git clone git://
Requires: nothing
Recommends: nothing
Suggests: nothing
See m_lib.txt.
The most interesting modules here are:
Get default encoding.
Flat ASCII Database; used in bookmarks_db.
progress bar for tty; used in bookmarks_db.


Bookmarks database and Internet robot - a set of programs I use to manipulate my bookmarks. Detailed description is available.
License: GPL
Download: sources and example shell scripts
git clone
git clone git://
Requires: m_Lib, other_Lib
Recommends: Beautiful Soup, html5lib, lxml
Suggests: nothing
Inside the archive:
Low level objects (Bookmark, Folder, etc) and framework for managing bookmarks tree.
HTML parsers based on BeautifulSoup, lxml, html5.
The program to convert bookmarks.html to a database.
The program to convert the database back to bookmarks.html.
The program checks URLs in the DB by running a robot (plugin).
The program converts the DB to a different format.
The program sorts the DB by add_date, last_visit, last_modified or size.
Prints a list of duplicate URLs in the database.
Directory with storage managers (DB plugins).
Directory with writers (data dumpers) plugins.
Directory with robots (URL checkers) plugins

MIME decode - a program to decode MIME messages. Useful for multicharset mail lists archives and such. Detailed description is available.
Download: mimedecode.tar.bz2
git clone
git clone git://
Requires: m_Lib
Recommends: nothing
Suggests: nothing
Inside the archive:,
The program.
Documentation source in DocBook format.
mimedecode.html,, mimedecode.txt
Documentation in different formats.


PEPs written by me.

rgb - an example of how to use PyGreSQL (PostgreSQL<=>Python interface)
License: GPL
Download: rgz.tgz
Requires: PyGreSQL, PostgreSQL, web server
Recommends: rgb.txt from X11
Suggests: nothing
Inside the archive:
Module that hides connection details; later if you want move/rename your database or programs, or change user/password, you just need to edit one file.
Program that parses rgb.txt (from X11, not included here) and put table of colors into rgb database. The database must exists, so run "createdb rgb" before
Very simple program that checks whether color parts are (not) exceeds 255.
The same as, but it combined with
CGI script that draws colors from rgb database and generates HTML table full of colors. The program wants one parameter "cube=N", where N is integer 1..8 - these are just 8 subcubes of big color cube.

Outdated code

skype4py-patches - 3 patches for Skype4py, the most notable is a patch to prevent segfaults.
License: Public domain
Download: skype4py-patches.tar.bz2
Requires: Skype4py
Upd. The patches were incoroprated into Skype4Py.
Inside the archive:
Initialize GLib to prevent segfaults.
Fixed the number of parameters for execlp call to start skype.
Allow to choose SystemBus instead of SessionBus on D-Bus.
Combined patch - all three in one.

other_Lib - modules written by other people.
License: unknown
Download: other_lib.tar.gz
Requires: nothing
Recommends: nothing
Suggests: nothing
Inside the archive:
This is rather old module that come before time.strptime() appeared in standard Python library (1.5.2). I extended it a bit and added Russian names for days, months, etc (both koi8-r and windows-1251 encodings).
My version of Neale Pickett's - object-oriented HTML generator.
A copy of

mCorrect - Some patches I made for standard library. Now mostly obsolete. Detailed description is available.
Download: mcorrect.tgz
Requires: nothing
Recommends: nothing
Suggests: nothing
Inside the archive:, tempfile.diff
DOS-related patches., os.diff
DJGPP-related patches.
Low-level classes to help implement DOS version of popen(). Actual implementation is in

Extract MIME - template programs that show how to write tools to extract MIME attachments from incoming mail messages. Detailed description is available.
Download: extract_mime.tgz
Requires: nothing
Recommends: nothing
Suggests: nothing
Inside the archive:
The template program.
Shell wrapper to use from /etc/aliases or such.

Netscape history dump/load - a pair of programs I used to manipulate Netscape browser's history.
Download: netscape-history.tgz
Requires: Berkeley DB 1.85 and builtin module bsddb
Recommends: nothing
Suggests: nothing
Inside the archive:
The program to dump history file to a text file. The program is based on Netscape history file lister by Hannu Krosing.
This is the opposite to dump - it loads the text file back to netscape history file. and mk_gdfonts - programs to convert BDF (XWindows) fonts to GD format.
Download: and mk_gdfonts
Requires: m_Lib
Recommends: nothing
Suggests: nothing
Program to convert BDF (XWindows) fonts to GD format. Tested with gd 1.2.
Shell script to generate all gd fonts in once.
My colleague Vitus Wagner maintaied a page with Cyrillic fonts, converted from fonts created by Sergey Vakulenko. Fonts tested with gd 1.2.

I wrote now old and outdated comparison of 3 Python-for-DOS interpreters.

This is the page It was generated on Mon, 24 Aug 2015 14:32:29 GMT from CheetahTemplate index.tmpl. Some rights are reserved. Read more about technical aspects of the site.