added watcher for debug mode