Fix python script