Skip to content

Bug: Editor fails to update workspace path cache after moving project folder out of OneDrive #30462

Description

@rsendres

Describe the bug

When moving a project folder from a OneDrive-synced directory (e.g., ~\OneDrive\Desktop\MyProject) to a local root directory (e.g., C:/Project/MyProject/), the editor persistently retains and restores the old file path in the workspace metadata cache.

Even when explicitly closing the old folder, opening the new folder via the UI, or clearing the recent history, the interface reverts to showing the previous OneDrive path and fails to recognize the new location until multiple restarts and project closures are performed.

Steps to reproduce

  1. Create or open a project located inside a OneDrive directory (e.g., ~\OneDrive\Desktop\MyProject).
  2. Close the editor.
  3. Move the project folder physically to a different partition or root path (e.g., C:\Project\ProjectName).
  4. Launch the editor and use File > Open Folder to select the new path (C:\Project\ProjectName).
  5. Notice that the editor UI still displays the old OneDrive path in the workspace header and fails to map the local files correctly.

Expected behavior

The editor should instantly flush the workspace path cache upon closing a folder or when a user explicitly loads a new directory via Open Folder, mapping the workspace context to the exact absolute path selected.

Environment

  • OS: Windows 10 / 11 (with OneDrive active)
  • Editor: OpenCode / Electron-based Workspace Environment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions