Archive for the ‘python’ Category

Here is a decorator that I came up with to augment the already available login_required and permission_required decorators. This one takes a group name and makes sure the logged in user is a part of it. def group_required(group_name,...

Have you ever wondered why you can't have manage.py sqlall output your create table statements as InnoDB tables for mysql? Well I have. I always go in and update the statements by hand to add that after the fact. So I did a bit of pokeing around and...

edit: # ericflo pointed out something that I totally forgot about... render_to_string. And he's completely correct... It does exactly the same thing and most likely does it better... DOH! Well whatever... here is my version anyway ;)...

So lately I've been working out all the kinks of running Django via pydev/eclipse so I can do more dev on my local machine. Since localy I run windows but I deploy onto Ubuntu Linux I've come up with a little hack that lets me conditionally load my...

Here is a graph I generated from trendrr.com to show how many search results google blogs returns for ruby vs python. It makes me happy on the inside to see them so neck and...

OK I'm going to be completely frank. You VERY likely could do this FAR better. But! I looked and have yet to see anything that does this for Django. So, here is my half ass'd attempt at two very helpful methods I picked up from my shady rails past. So by...

Flickr Pics

13th and washington NYC13th and 9th NYC1st st Jersey CityIMG_2813IMG_2814_2IMG_2816IMG_2815Photo_011908_001Photo_122807_001Photo_121107_001