Update with stack-of-tasks fork

I had some problems using the embedded python interpreter, in particular I experienced problem related to the coexistence of several python threads. The problem and a possible solution is explained here [1], so I did a simple fix in interpreter.cc using the Global Interpreter Lock before each python call.

[1] https://docs.python.org/2/c-api/init.html#thread-state-and-the-global-interpreter-lock