Tag Archive: python


Bad Error Message is Unhelpful

So, I’m still learning Django and have a long ways to go, but the following error is extremely unhelpful: “TemplateSyntaxError: Invalid block tag: ‘else’, expected ‘else’ or ‘endif’” The problem is, Django doesn’t do else if, but my editor does highlight it as if it’s correct. You then get this error message, but have to …

Continue reading »


Git Is Finicky

So, we have a release happening soon, and I needed to cherry-pick a few essential changes into the release candidate and upon trying to push them, I was told everything was up to date. ORLY NAO? Apparently, every now and again Git decides it wants to mess with me, and today is one of those …

Continue reading »


MacVim PEP-8 Helper

To follow along with PEP-0008 standards, there is a command that will highlight any characters beyond the 79 char limit.  It’s a useful little reminder that you’ve reached your limit. :match ErrorMsg ‘\%>79v.\+’


Sphinx Docs

So we’re adding auto-doc’ing capabilities to Nudge, and I’m in charge of Sphinx docs right now.  They’re a PITA…  One space is off? FFFFFFUUUUUUUUUUUUUUUUUUU.  Yup about that awesome.  They also don’t like having table items be longer than the column separators.  I’m not sure what they’re really called, but they’re the set of = signs …

Continue reading »



Recently, whenever I have downtime on the couch I try to learn something new about Python.  For the moment that learning has come through reading other people’s questions on Stack Overflow or the Python subreddit. Last week, I learned about setdefault(‘key’, default_value), and I got a lot of satisfaction while working on Nudge during the …

Continue reading »


Things I need to remember about Python #1

dicta.update(dictb) DOES NOT RETURN ANYTHING. It modifies the dictionary in place, so if you do dicta = dicta.update(dictb) dicta will now be None. Thanks brain. Let’s hold onto this.