refactor: use os.devnull instead of /dev/null