fixing pyret mode