extract get_dir_paths from find_executable
BUGFIX: update external.dir_paths access to fix NameError