fix watch when file is currently being written
added set