change codes to fit in cadquery module