Be more Python 3 friendly

Signed-off-by: Sebastian Ramacher <sebastian+dev@ramacher.at>