home | talks | photos | about | resume | contact

Python AST

This talk was given to the Cleveland Python Users Group in March 2009.

The talk covers the Abstract Syntax features in Python from their introduction in 2.3 all the way through the current state of AST in 2.6 and 3.0. This is a high-level overview with a couple of interesting use cases for the AST module. The talk covers the module itself and the underlying techniques that are used to generate the AST tree including a short tour of the Python parser.

Presentation Slides

Pointy­ Haired Bosses and Pragmatic Programmers

The keynote at CodeMash this morning was really excellent. Venkat Subramanian
made some excellent points about testability, maintainability and outsourcing.
Continue reading ‘Pointy­ Haired Bosses and Pragmatic Programmers’

Impressions of .NET

Today I spent the entire day in the .NET session at CodeMash. Now I have pretty much no practical interest in .NET but the whole point of CodeMash is to expand your mind, so why not. I was pleasantly surprised and in cases downright impressed. Continue reading ‘Impressions of .NET’

Going to CodeMash

I’ll be at CodeMash next week. Anybody else going?
Continue reading ‘Going to CodeMash’

This Site Brought to you By Nginx

As of today this site is being served using Nginx!

After spending a little bit of time messing around running lighttpd on some personal stuff at home I decided to give Nginx a whirl this weekend and it’s quite awesome. So awesome in-fact that I’m now working to totally replace Apache with Nginx (that’s no small tasks for 60+ sites).
Continue reading ‘This Site Brought to you By Nginx’

Lesson Learned: Don’t Monkey Patch

Well this post comes as a lesson learned the hard way and a warning to fellow programmers in dynamic languages. In a sentence, don’t monkey-patch. Seriously, just don’t do it.
Continue reading ‘Lesson Learned: Don’t Monkey Patch’

Perl from Python? Intriguing yet gross.

So I’m probably late to the party on this one but apparently you can import perl from within python. Now, why you would want to do this kind of baffles me, however, it is really pretty interesting and could have some possibilities if you’re maintaining a legacy perl application that you’re porting to python. If nothing else its an interesting academic exercise.

Mac Terminal Keys

One of the most annoying things with Apple’s Terminal.app is that the key bindings for paging an home/end are all kinds of screwed up. I’ve actually had these on my MBP for a while but was setting up a new Mac today and figured I’d throw them out here for the benefit of the rest of the web.
Continue reading ‘Mac Terminal Keys’

iPython Readline on Leopard

iPython is a really great tool for working with Python interactively but its less than awesome on Leopard. Why you might ask? Well, included in the list of sins Apple has comitted with Leopard’s terminal environment was shipping a broken version of readline. The good news is it’s easy to fix! The iPython folks have a version of readline that works on Leopard. Just easy_install it and rock out with full readline support, including working home and end keys.

1
sudo easy_install -f http://ipython.scipy.org/dist readline

Custom Terminal Colors on Leopard

The Apple terminal is arguably one of the places I spend the most time on my mac, but the program is quite lacking. Apple did a good job improving it in Leopard but they just didn’t quite fix everything that was broken.

Among its issues is the fact that there is no built-in way to handle changing the default colors. This probably makes sense if you’re looking at a white terminal with colored text on it. However if you’re like me and find black or very dark backgrounds less abusive to your eyes you’ve no doubt found some of the colors utterly miserable to read, especially blues.

Well after find out that a co-worker was having similar issues I did some digging and found an absolutely amazing SIMBL plugin by Ciaran Walsh (of TextMate plugin fame) that fixes that. Check it out at his site. It’s probably one of the more useful plugins I have.

Screenshots and notes after the jump.

Continue reading ‘Custom Terminal Colors on Leopard’

DISCLAIMER: The opinions expressed on this website are mine and mine alone, they should not be interpreted as the views of my employers, past or present, my family, my church or my pets. Comments are the property of their posters and I can not be held accountable for those.