Fix for python3

Signed-off-by: Jonas Kalderstam <jonas@kalderstam.se>