Wordpress - ionelmc.wordpress.com - ionel's codelog
General Information:
Latest News:
Django and pip wheel 26 Aug 2013 | 02:00 am
Just a quick heads-up: older Django versions don't work properly if installed via wheel. It's fixed in 1.6 but it's not final yet (right now it's in beta). Edit: Django 1.5.2 has the fix backported fr...
Dealing with eval'd code 8 Aug 2013 | 02:00 am
eval and exec are usually frowned upon, for good reason. The main issues people complain about are: Security: cause user input might end up in the eval'd string. And users are not to be trusted. Slo...
Testings Python warnings 25 Jun 2013 | 02:00 am
If you're unittest-ing your code and that code issues some warnings using warnings.warn you should make some assertions for those messages too. You probably do it because you're deprecating some API ...
Serving files if they exist or fallback to wsgi app 14 Jun 2013 | 02:00 am
We want to achieve this routing scheme: /anything => static file, if it exists ! / => the wsgi app For some reason this isn't as straightforward as in Nginx. Example [1]. With Apache you have to e...
Python profiling tools 8 Jun 2013 | 07:47 pm
This is a small addition to the previous article about the debuggers. The stdlib has 3 backends (cProfile and profile , hotshot) and countless 3rd party visualization tools, converters and whatnot. W...
Python debugging tools 5 Jun 2013 | 02:00 am
This is an overview of tools I've used for debugging or profiling purposes. Not necessarily complete, if you know better tools, comment below. Logging Yes, really. Can't stress enough how important ...
Migrated to github pages 30 May 2013 | 02:16 am
I’ve migrated this with Pelican to blog.ionelmc.ro. It’s hosted on github pages (sources on github repo). Tagged: python
Mysql too slow in tests ? ramdisk it ! 30 May 2013 | 02:00 am
Suppose you're doing it wrong: you're using MySQL and your test suite is slow very slow. MySQL is very slow at DDL statements so creating/clearing/loading that test database all the time is going to b...
Old Ubuntu 10.04 on Hyper-V 11 Mar 2013 | 05:12 pm
If you have to install 10.04 in a Hyper-V you might have some trouble if you want network. I’ve tried 11.10 and it has the same problem. Only 12.04 works out of the box with no fixups. The first thing...
Old Ubuntu 10.04 on Hyper-V 11 Mar 2013 | 05:12 pm
If you have to install 10.04 in a Hyper-V you might have some trouble if you want network. I've tried 11.10 and it has the same problem. Only 12.04 works out of the box with no fixups. The first thin...