Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion agent/subdirectory_hints.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,10 @@ def _add_path_candidate(self, raw_path: str, candidates: Set[Path]):
if parent == p:
break # filesystem root
p = parent
except (OSError, ValueError):
except (OSError, ValueError, RuntimeError):
# RuntimeError covers Path.expanduser() on a "~user" token whose
# user is not a real account ("Could not determine home directory.").
# The hint walk is best-effort, so a bad path is skipped, never fatal.
pass

def _extract_paths_from_command(self, cmd: str, candidates: Set[Path]):
Expand Down