You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
File > Set Dev Directory throws on the render thread for a relative, ~ or quoted path #478
The "Set Dev Directory" popup callback (ProjectDirector/ProjectDirector.cs:876-885) passes whatever the user typed straight to AbsoluteDirectoryPath.Create<AbsoluteDirectoryPath>(result). The only guard is string.IsNullOrEmpty.
With ktsu.Semantics.Paths 5.11.0 (the pinned version), these inputs all throw ArgumentException: Cannot convert "..." to AbsoluteDirectoryPath:
dev (relative)
~/dev
" /tmp/x" (leading space)
"\"C:\\dev\"" (quoted)
The callback runs from PopupSetDevDirectory.ShowIfOpen() inside Tick (ProjectDirector.cs:684), which is the render thread. Nothing there catches the exception, so it escapes the render loop and takes the app down. #440 and #444 treat a throw on the render thread the same way.
Failure scenario
On Windows, a user copies their dev folder with Explorer's "Copy as path", which wraps it in quotes ("C:\dev"). They paste it into the popup and press OK, and the app crashes. Typing ~/dev or a relative folder name does the same.
Suggested fix
Trim whitespace and a surrounding pair of quotes from the input.
Optionally expand a leading ~ to the user profile directory.
Validate with Path.IsPathFullyQualified, or catch ArgumentException. On rejection, QueueLog the reason and keep the previous DevDirectory.
Acceptance criteria
Entering dev, "C:\dev", ~/dev or " C:\dev " never throws.
Each input either sets a valid absolute DevDirectory (for the quoted and padded cases) or leaves it unchanged and logs why the input was refused.
Priority: High. Ordinary input crashes the app: a path from Explorer's "Copy as path", ~/dev, or a relative folder name. The exception escapes the render loop.
Area / suggested assignment: Popup and input handling on the render thread (ProjectDirector.cs, the PopupSetDevDirectory callback).
Notes: Trim whitespace and quotes, optionally expand ~, then validate with Path.IsPathFullyQualified. On rejection, QueueLog the reason and keep the previous value. A small, self-contained fix.
Activity
matt-edmondson commentedon Oct 6, 2026
Triage
~/dev, or a relative folder name. The exception escapes the render loop.ProjectDirector.cs, thePopupSetDevDirectorycallback).src/src/...folders #440 and Scanning or adding a GitHub owner crashes on a 404/401/rate limit instead of skipping the owner #444 (render-thread throws). Dev-directory scan crashes the app on any inaccessible or locked subfolder #425 (closed) was a different dev-directory crash.~, then validate withPath.IsPathFullyQualified. On rejection,QueueLogthe reason and keep the previous value. A small, self-contained fix.Generated by Claude Code