Fixed python script