Jacob Kaplan-Moss

Activity tagged “python”

Bookmarks

Let's talk about Python 3.0

It uses Python 3 or it gets the hose. On a more serious note, James absolutely nails it w.r.t Python 3.

(python, python3)

Mock It!: An lxml you can bank on

Finally! easy_install staticlxml and done.

(eggs, lxml, mac, osx, python)

Python Package Index : collective.buildbot 0.3.3

A set of zc.buildout recipes that make it *stupidly* easy to configure and set up a buildbot master or slave — it's literally like six shell commands to get a dummy buildbot going. Totally freeking awesome.

(buildbot, buildout, python, zc.buildout)

Intro to Unintrusive JavaScript with Django @ Irrational Exuberance

A wonderful introduction to making AJAXy sites with Django. Make sure to pay attention to the first step: “the first step to implementing an Ajax webapp is to implement the webapp without Ajax.” Word.

(ajax, django, python, tutorial)

The Fluther Blog » Blog Archive » mogileFS for Django

How to integrate Django 1.0's file storage APIs with MogileFS.

(django, hosting, mogilefs, python)

djangopony - Magic that can't be removed.

I literally laughed so hard I nearly fell out of my chair.

(awesome, django, djangopony, fun, funny, humor, pony, python, web)

CleverCSS

Like those hackish CSS preprocessors that everyone writes when they get pissed about CSS's lack of variables, except actually well-thought-out and basically awesome. I think I'll be using this for my CSS from now on.

(clevercss, css, desgin, python, software, via:twid)

Django cheat sheet (Mercurytide)

Really purty one-page cheat-sheet, updated for Django 1.0.

(cheatsheet, django, python, reference)

Simon Willison: Announcing dmigrations

The schema evolution in Django space is really heating up. With luck we can keep the competition friendly, and pull out a best-of-breed solution to roll back into Django.

(database, db, django, evolution, orm, programming, python, schema)

Zookeepr | Main / HomePage browse

A conference management package developed by LCA.

(conference, linux, python, software, web)

Keyphrene - 4Py Homepage

Wrappers for OpenSSL and LibSSH2.

(python, security, ssh, ssl)

Simple Top-Down Parsing in Python

Fantastic article on building a top-down parser in just a few hundred lines of Python. Read this even if you don't care about parsing: effbot really demonstrates many of the cool idiomatic tricks that makes Python such a pleasure to write and read.

(algorithms, programming, python)

Fusil - Trac

A library for writing fuzz testing programs.

(fuzz, python, testing, tools)

pgmigrate - Google Code

Another database migration tool. This one's not Django-specific (though it will work with Django), but it is PostgreSQL specific. I'm really quite happy with the competition in this space right now; it'll force any eventually Django built-in migration to

(database, migration, postgresql, python, schema, tools)

Annotype

Neat script I wrote for a friend to annotate a Python script with the types observed during a run of the program.”

(code, languages, programming, python, types)

Debian User Forums :: View topic - Etch and Python 2.5

How to make Python 2.5 the default on Debian Etch

(debian, python)

Ian Bicking: Python HTML Parser Performance

The short version: lxml kicks ass.

(html, lxml, parsing, python)

Proven Corporation » Blog » Sphinx Templates

Some nice notes on how the Sphinx templates are laid out.

(documentation, jinja, python, sphinx, templates)

[Python-Dev] PEP 361: Python 2.6/3.0 release schedule

Executive summary: Python 2.6 and 3.0 finals are planned for September 3, 2008.” Woo!!

(python, python3000)

Dino's Blog : IronPython, MS SQL, and PEP 249

How to run Django (0.96) on IronPython, including an MSSQL backend.

(clr, django, dotnet, ironpython, python)

Elegant Stitches

The folks that made the Django Ts and hats for PyCon, as well as all the great Python gear for sale. Great quality and great people!

(clothing, python, shopping)

Python Package Index : haufe.eggserver 0.1.10

haufe.eggserver is a tiny webfront to a local egg/sourcecode archive distribution directory (eggs and other distribution files stored directly on the filesystem).

(distutils, eggs, pypi, python)

Writing Python/C extensions by hand

An exploration of writing a Python/C extension in pure C versus using ctypes. The takeaway is that ctypes is slower, but easier.

(c, ctypes, python)

xmldiff

a python tool that figures out the differences between two similar XML files, in the same way the diff utility does” Seems a bit buggy, but might be useful

(diff, python, tools, xml)

James Henstridge » Two‐Phase Commit in Python’s DBAPI

Two-phase commit proposal for Python. A bit esoteric, but this could help us crazy ORM weenies a bit.

(db, dbapi, programming, python, sql)

iCalendar package for Python

Another iCalendar library. This one has perhaps the best API of all the ones I've used and seems to work with all the iCal feeds I've thrown at it.

(calendar, ical, icalendar, library, programming, python)

Python Package Index : magicdate 0.1.3

A plugin for optparse to do fuzzy dates. Lets your CLI scripts take arguments like “—start today —end tomorrow”; very cute.

(datetime, optparse, python)

Python Package Index : Fabric 0.0.3

… a bit like a dumbed down Capistrano, except it's in Python, dosn't expect you to be deploying Rails applications, …. Unlike Capistrano, Fabric wants to stay small, light, easy to change and not bound to any specific framework.”

(deployment, python)

Coder Who Says Py: Initial slides for PyCon core development tutorial online

Brett's (preliminary) slides on contributing to Python. I need to prepare something similar for Django.

(development, opensource, python, slides)

Writing An Hadoop MapReduce Program In Python - Michael G. Noll

Neat. I hadn't realized that Hadoop map/reduce jobs could be a bog-standard shell script. It's especially cute that testing the job comes down to “cat data | map | reduce”.

(hadoop, mapreduce, python)

[Python-Dev] Monkeypatching idioms — elegant or ugly?

A bit of code from GvR to make monkeypatching look cleaner. Very clever (of course), though I'm not sure how much I like it: I *like* that monkeypatching looks ugly in Python; it makes the monkeypatch code smell more obvious.

(monkeypatching, python)

InstallationOSXLeopard - IPython

Finally, a working readline for Leopard: “easy_install -f http://ipython.scipy.org/dist/ readline”

(osx, python, readline)

g :: A Simple Plugin Framework

Marty implements a plugin architecture in six (brilliant) lines of code.

(framework, plugins, programming, python)

StaticGenerator for Django

A cool idea: pre-bake static pages generated by Django. Sometimes simple is better.

(django, performance, python)

Utilitymill's developer comments on the security model

Sounds relatively smart. However, I'd be suspicious of using chroot — I'm told it wasn't especially designed to be a security feature exactly. Were I to do something of this nature, I'd probably use pypy-sandbox.

(chroot, python, sandbox, security, utilitymill)

Front Range Pythoneering: Django on Jython: Minding the Gap

The Front Range Pythoneers strike again: Django now runs pretty well on Jython. This really is a big deal.

(django, java, jython, python, webdev)

Handwriting on the Sky - Export for Python

A neat idea: explicitly control which symbols a module exports. It smacks a bit of B&D programming, but could be useful.

(export, module, namespaces, python)

macosxhints.com - 10.4: Combine PDFs without using Automator

Man, OSX ships with all sorts of gems.

(osx, pdf, python)

Revision 59590: /doctools/trunk

The new toolchain for the Python docs. Lots of smart stuff going on in here.

(documentation, docutils, markup, python, restructuredtext, tools)

PyRTF - Rich Text Format (RTF) Document Generation in Python

RTF generator written in Python. Looks like a docutils writer based on PyRTF should be pretty trivial, and that might make a better reST -> Word workflow than my current reST -> ODF -> OO.org -> Word nonsense.

(library, programming, python, rtf, text)

xkcd - A webcomic of romance, sarcasm, math, and language - By Randall Munroe

XKCD discovers what we've known all along. Let the latest battle in the language wars begin.

(comic, python)

Eventlet - Second Life Wiki

Non-blocking IO library by Linden Lab. I've heard awesome things about this; gotta give it a try.

(code, concurrency, networking, programming, python)

http://svn.red-bean.com/pyobjc/branches/pyobjc2/pyobjc-core/NEWS.txt

All (and there's lots of it) the new stuff in PyObjC 2 (i.e. the version in Leopard). Really, really nice stuff here.

(leopard, mac, pyobjc, python)

OS X Automation » Blog Archives » IPython tab completion fix on Leopard

Good thing someone figured this out — without ipython I don't know how I'd get any work done!

(ipython, leopard, python)

IBM’s Python and DB2 drivers released | Zen and the Art of Ruby Programming

Sweetness. Hopefully someone'll use this to work on a DB2 driver for Django.

(db2, ibm, python)

PyCha - Trac

Python charting package. Yes, it's YA, but this one uses Cairo and looks *nice*.

(cairo, charting, library, python)

Python Package Index : IPy 0.51

Nice utility class for dealing with IPv4/IPv6 addresses. Especially nice is the netmask handling; I never have been very good at calculating netmasks by hand.

(code, ip, network, programming, python)

ASPN : Python Cookbook : Getting items in batches

I never remember how to do this right. Don't miss the comments for Raymon Hettinger's amazingly clever version.

(batch, code, list, programming, python)

Jaiku | most of jaiku's stuff is written in python using twisted, and devku is running django

Apparently Jaiku is using Django internally, which means Google's now using Django in yet another place.

(django, google, jaiku, python)

Apple Bits

Scroll to the bottom for extractkeychain.py, a quick script to dump keychain passwords to plaintext (you *are* piping that into GPG/OpenSSL, right?)

(keychain, osx, python)

The Py Side of Life: String types in Python 3

Some important notes about strings in Python 3. There's a subtle but important change from 3a1: the bytes type is now immutable. This is a good change IMO; the net result sounds very sane.

(python, python3, strings, unicode)

tranquil - Google Code

Beautifully simple Django/SQLAlchemy integration layer that automatically maps Django models into SQLAlchemy ORM objects. In theory a similar approch would allow SQLAlchemy objects to be exposed as Django models; that would kick ass.

(django, orm, python, sqlalchemy)

parsedatetime project

From the Chandler project, a Python module to parse “natural” datetime constructs (i.e. “tomorrow”, “next monday”, and even “two weeks from last thursday at noon”). The API is shitty and Java-esque, but the functionality is great.

(datetime, library, naturallanguage, python)

py-bcrypt - strong password hashing for Python

We should support bcrypt in Django if this module is installed.

(cryptography, django, encryption, library, python, security, todo)

Memory Dump » Blog Archive » Zope3 for Djangoers. Part 1: Installation

This looks great. All my Zope knowledge comes from the hairy Zope2 days, so I really need to brush up on the brave new world of Zope.

(django, python, tutorial, via:simonw, zope)

BabelDjango - Babel - Trac

Interesting work to integrate Django and Babel. Even if you don't need translation, there's some useful date/time/decimal formatting template filters here.

(babel, django, i18n, opensource, python, translation)

ElementTree: Working with Namespaces and Qualified Names

Required reading for working with namespaces and ElementTree. It's not hard, but there are a lot of details to get right.

(elementtree, namespaces, python, xml)

From Rails to Django — Myles Braithwaite

Recently I switched all of my websites to Djanog from Rails and you can see the difference.” Wow, an amazing difference in RAM consumption. Especially surprising given that Python/Django isn't exactly known for low memory usage.

(django, python, rails)

Gruber: “If Python 3.0 ships before Perl 6, I'm going to cry”

Someone order the man some Kleenex; he's gonna need 'em.

(funny, perl, python)

The Hand of FuManChu - Storm, SQLAlchemy, and Geniusql

Not sure about the quality of the benchmarks, but I'd nevertheless still like to see how Django stacks up here. Not very well I'd imagine, but Django's always been an 80% ORM anyway, so 80% of the performance would be just *fine* with me.

(benchmark, geniusql, orm, performance, programming, python, sql, sqlalchemy, storm)

livinghardknox » Blog Archive » Django and the iPhone

Sweet - someone wrote up the (simple) steps to getting Django running on an iPhone. Now I don't have to!

(django, howto, iphone, python)

http://svn.colorstudy.com/home/ianb/recipes/patmatch.py

Erlang-ish pattern matching in Python, from Ian Bicking.

(code, erlang, patternmatching, python)

PyBugz - Python Interface to Bugzilla | liquidx

Python-based command-line front-end to Bugzilla.

(bugs, bugzilla, python)

Python Cheese Shop : threadpool 1.2.2

A nice and simple producer/consumer threadpool utility. Hooray for doing the simplest possible thing.

(code, python, threading)

Pyglet: /trunk/tools/wraptypes

A tool for parsing C header files and generating ctypes wrappers. From the pyglet project, which includes ctypes wrappers for OpenGL. I'm not sure if this is tunned specially for OpenGL, but if it's roughly generic it could save *lots* of time.

(c, code, codegeneration, ctypes, generated-by-a-computer, headers, opengl, parsing, python)

lwqueue: Lightweight cross-language message queue system

A stab at a memcached-like message queue. Looks super-simple, and 1000 op/s isn't half shabby.

(code, distributed, messaging, programming, python, queue, scaling)

dpaste: #14224: anyetree

I got frustrated by the etree import dance, so I wrote this.

(elementtree, etree, python)

Ned Batchelder: hyphenate

Frank Liang's hypenation algorithm (i.e. the good one that TeX uses) in Python.

(code, hyphenation, library, python)

templatemaker - Google Code

Adrian's “reverse template engine:” take a series of files and construct a template that could have been used to generate those pages. Obviously extremely useful for data scraping.

(code, friends, python, scraping)

Now with Django powered goodness!

Antonio on Django/Tabblo: “the HP folks doing diligence on us started by asking why we had not chosen Ruby on Rails and came out the other end incredibly impressed with our Django choice.”

(django, propaganda, python, web)

gameobjects - Google Code

Game Objects is a collection of 2D and 3D maths classes, and algorithms for helping in the creation of games with Python. Suitable for PyGame, but independent of it.”

(game, math, programming, pygame, python)

The Future of TurboGears - TurboGears | Google Groups

TurboGears 2.0 will be built on top of Pylons. This is a very good thing for the Python web community. This has majorly cool implications for Django, too, so I better get my butt in gear and start coding.

(programming, pylons, python, turbogears, webdev)

ASPN : Python Cookbook : xml reverse-engineering ElementTree code generator (*whew*)

takes an ambiguous xml file and generates the ET code to generate that xml file”

(ElementTree, python, xml)

Django-fr | Le Framework Web python pour les perfectionnistes

The “official” (well, as official as it gets) version of the Django site.

(django, fr, framework, french, python)

Python - F8

PyFacebook — Python wrapper for the Facebook API. Uses Django by default.

(django, facebook, python)

Book - NLTK

A book on natural language processing in Python.

(book, code, language, opensource, programming, python)

techspot.zzzeek.org » Blog Archive » Polymorphic Associations with SQLAlchemy

A good explanation of the underlying SQL behind polymorphic associations. This is how Django does so-called “generic relations” (through a centralized content-types table instead of the address_associations table here).

(orm, python, sql, sqlalchemy)

PEP 2 — Procedure for Adding New Modules

This is how Python does additions to the stdlib. We probably should look to do something similar…

(django, process, python, stdlib)

snakefood: Python Dependency Graphs

For a while now I've been talking up the new things Python 2.5's AST will allow; this is just the tip of a very exciting iceberg.

(analysis, ast, dependency, graph, python)

Python Cheese Shop : processing 0.21

Package for using processes which mimics the threading module, and allows the sharing of objects between processes.”

(concurrency, library, processes, python)

plasTeX - LaTeX Document Processing Framework

Pure Python LaTeX parsing/processing tools. Neat.

(latex, parser, python)

How to Write a Spelling Corrector

Awesome article on how you can write a simple spelling corrector in a handful of lines of Python.

(code, probability, programming, python, spelling)

matplotlib without a GUI

Useful notes on using matplotlib without the pylab interface.

(graphics, matplotlib, python)

ModPython/Articles/ExpatCausingApacheCrash - Graham's Project Wiki

Great writeup of *why* expat can cause mod_python to segfault. The mod_php + mod_python crashes that some Djangonauts see happen for exactly the same reason, so the debugging advice here is useful there, as well.

(apache, debugging, django, expat, modpython, python, segfault)

Bitten - Trac

Continuous integration tool that integrates with Trac. We really should get this set up for Django…

(python, tools, trac)

Ask Reddit: How did you end up using Django? (reddit.com)

A good collection of stories from Django users. Gives me the warm fuzzies :)

(development, django, for:holovaty, programming, python, web)

CPS Project: NXLucene

Another Lucene-based web service tool (this one based on Plone)

(code, indexing, java, lucene, pycon2007, python, search)

Welcome to pyglet

Pyglet is a cross-platform gaming / multimedia library written in pure Python.” Built on OpenGL.

(development, game, graphics, library, pycon2007, python)

pythong.org.

These guys have some interesting ideas about Python Packaging.

(for:holovaty, for:jcroft, for:korpios, for:mcroydon, for:sketch22, pycon2007, python)

svn-foreign

A tool to review an svn repository with new files/conflicts and quickly decide what to do with them. Pretty nifty.

(pycon2007, python, svn, tools)

pydoctor

YA python to API doc tool. But this one's by mwh, so it's likely a cut above.

(development, documentation, generator, programming, pycon2007, pydoc, python, tools)

Voting Research

Ping's page on his voting research. Some hackers hack code, others hack democracy.

(politics, pycon2007, python, security, visualization, voting)

Connectors for the NdbApi in Launchpad

Low-level database connectors for MySQL. Essentially you get to use a relational database without SQL. Could be very interesting when combined with an ORM.

(database, development, library, mysql, programming, pycon2007, python)

PythonTestingToolsTaxonomy - Cheesecake - Trac

An amazing breakdown of the various Python testing tools — there are even more of them then web frameworks!

(code, lists, pycon2007, python, testing, tools, webdev)

Unipath

Treat paths as objects, not strings. Even better than Jason's path.py, and there's even a chance this one'll end up in Python's stdlib.

(filesystem, for:mcroydon, path, python)

tfclassify - Trac

A document classification algorithm. Wonder if it would be useful for classifying stories…

(categorization, classification, for:mcroydon, python)

rnc2rng

Python code to convert RelaxNG Compact to the XML syntax.

(code, python, relaxng, xml)

Python Goodies

smtpd.py — if it's good enough for Guido, it's good enough for me.

(mail, python, smtpd)

VObject Home

Matt says this is a better iCal library than the other two I just bookmarked…

(calendar, code, dataformats, ical, library, python, via:mcroydon)

Python Cheese Shop : calcore 2.1.0

CalCore is an advanced, flexible calendaring component for Python. It allows the Python developer do write advanced calendaring applications either using their own event storage or integrating with external calendar servers.”

(calendar, dataformats, library, python)

Python Cheese Shop : itools 0.14.3

A bunch of format tools; itools.csv, itools.ical, …

(dataformats, library, python)

Open Source Flash - flashticle

flashticle is a MIT licensed Python 2.4 library implementing various Macromedia Flash related data formats and protocols. flashticle is sponsored by Mochi Media, LLC.

(flash, python)

ASPN : Python Cookbook : Automatic Southwest Boarding Pass

Travellers who fly Southwest airlines know all too well the importance of “getting an A” so they can board in the first boarding group… With this script you will never again miss “getting an A” regardless of when your flight is.”

(funny, python, scripts, southwest)

Python and Microsoft Access

Using the Jet engine (MS Access) from Python on Windows

(database, msaccess, python, windows)

Python Web Framework Statistics

Python Web Framework Statistics

(django, python, stats, webdev)

nabu: a Publishing System using Text Files

Nabu is a simple framework that extracts chunks of various types of information from documents written in simple text files (written with reStructuredText conventions) and that stores this information (including the document) in a remote database for late

(python, text, web)

PyRRD - Trac

Pythonic RRD bindings — only just getting started, but already quite a bit nicer than the standard bindings.

(python, rrd)

Django | Snakes and Rubies downloads

Video and audio from the Snakes and Rubies event

(audio, django, ego, mp3, python, rails, ruby, snakesandrubies, video)

PySyck

PySyck is aimed to update the current Python bindings for Syck. The new bindings provide a wrapper for the Syck emitter and give access to YAML representation graphs. Hopefully it will not leak memory as well.

(programming, python, yaml)

from __future__ import * » simple_json 1.0

MIT licenses JSON encoder/decoder in Python. Besides the better license, the code is much clearer than json-py

(django, javascript, json, python)

Snakes and Rubies :: Index

Witness an epic battle of Those WIth Strange Last Names Who Write Web Frameworks

(chicago, django, python, rails, ruby, webdev)

[boston-pig] TurboGears vs. Django

A very good and fair comparison of Django and TurboGears

(django, python, turbogears)

svnperms.py

A hook script for SVN that can be used for fine-grained permissions.

(python, svn)

Using reST with wordpress

I've been looking for something like this!

(python, rest, wordpress)

PyCon DC 2005 Call for Proposals

Deadline is Dec 31st — get your act together, Jacob!

(python)

securehidden.py (Ian Bicking)

Generate secure values for hidden input fields that can't be tampered with

(python, webdev)

Entries

Five things I hate about Python

Inspired by Titus (who was in turn inspired by brian d foy), here’s what I hate about Python. I completely agree with Brian that you can’t trust any advocate who doesn’t know enough to find stuff to hate. Given that I spend a lot of time advocating Python, writing down what I hate seems a good exercise.

(hate, python)

Photos