This post originated from an RSS feed registered with Python Buzz
by Aaron Brady.
Original Post: Writing Public Code
Feed Title: insom.me.uk
Feed URL: http://feeds2.feedburner.com/insommeuk
Feed Description: Posts related to using Python. Some tricks and tips, observations, hacks, and the Brand New Things.
When writing code "for public consumption" or even just for display,
I dislike releasing proof-of-concept code. Sure, I have 10 minute
hacks in my snippets section, but what about the longer pieces that
aren't polished, but are still good?
I have two specific pieces of code: one which takes an image as a
parameter and creates a thumbnail of it with a pretty border gleaned
from another image, and one which decodes barcodes from images.
Both of these pieces of code are conceivably useful to someone,
but they are full of unexplained (magic) constants, bad variable
names that put typing speed above readability, hardcoded defaults,
and are almost totally void of comments.
It pains me to release them, but I haven't posted anything
substantial in months, and most of it comes from the fact that even
when I get time to write some code, I rarely have time to polish to
the level that I consider fit for public consumption.