fixed python modifier management