replace set::{exists,remove,read} with open