fix: make Home working directory writable - #7773
Conversation
|
Thanks @Hendrikc4 — this is a nicely scoped fix for the writable-workspace path, especially the split between |
|
🧪 This PR has changes that need a manual QA pass before merge — please hold off self-merging for now; we'll loop QA in once it's merge-ready (and design/product have signed off, where applicable). |
mrcfps
left a comment
There was a problem hiding this comment.
@Hendrikc4 thank you for this — it is a focused, well-aimed fix for the Home working-directory path.
I reviewed the live diff at 8821d45b12da5496904803692bd1f7841967ba5f. Home now stamps userWorkingDir plus the host token instead of classifying the picked folder as read-only linkedDirs, desktop recents re-open the native picker so a remembered path cannot skip authorization, and POST /api/projects/:id/working-dir drops the transient hint while realpath-filtering linkedDirs so a promoted folder (including symlink aliases) does not stay --add-dir read-only. That matches the existing App.tsx handoff, which already spends the token before upload or auto-send. The web, daemon, and e2e specs were updated to the new create contract.
Really nice work on the baseDir vs linkedDirs split and the red-spec coverage. 🙏
🔁 Powered by Looper · runner=reviewer · agent=omp · An autonomous AI dev team for your GitHub repos.
















































Addresses #7643
Why
I hit this on macOS with OpenDesign 0.21.1 while trying to use an existing repository as the working directory for a new project.
The Home “Working directory” control opened the trusted native folder picker correctly, but project creation then treated the chosen folder as linked reference code. That made it read-only and started the agent in OpenDesign's generated project folder instead.
The picker already returns a short-lived authorization token, and the app already has a safe working-directory update flow. The missing piece was passing the chosen folder and token into that flow instead of converting the folder to linkedDirs.
Issue #7643 also contains broader project-discovery concerns. This PR addresses the working-directory/cwd part without claiming to close the entire issue.
What users will see
Selecting a Working directory on Home now makes that folder the writable workspace for the new project.
Surface area
Screenshots
No visual layout or copy changes. This corrects what happens after using the existing Home → Working directory picker.
Manual macOS verification used the existing control and confirmed a new session started in /Users/hendrik/coding/startupseeker_v2, could create and remove a probe file there, and persisted the repository as baseDir rather than linkedDirs.
Bug fix verification
Validation
For transparency, I also started the full daemon suite. Four unrelated tests in od-next-automatic-simple-server.test.ts timed out amid their existing closed-database watcher noise, so I stopped that long sweep after the failures. The complete touched daemon test file passes, and none of the timeout failures exercise working-directory or import behavior.