This syntax is not Python 2.4 compatible.  You'll need to use a traditional if ... else block here (and below).