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
Description:
Perforce operations via the VSCode Perforce extension currently fail when performed on files that are inside the Perforce workspace but accessed via symlinks. The extension treats such files as being outside the depot, likely because it uses the symlink path rather than resolving to the actual file path in the workspace.
This is a usability issue for setups where projects are organized using symlinks (e.g., monorepos, sandboxed dev environments, shared modules, etc.).
Steps to reproduce:
Create a Perforce workspace and sync a depot.
Create a symlink pointing to a file or folder within the workspace.
Open the symlinked path in VSCode.
Try running a Perforce command (e.g., edit, diff, submit).
Expected behavior:
The extension should resolve the real path of the file (e.g., using realpath) before passing it to Perforce commands, allowing them to succeed as expected.
Actual behavior:
Commands fail, with messages indicating the file is not under Perforce control.
Suggested Fix:
Use realpath (or equivalent path resolution APIs in Node.js) to resolve symlinks before executing Perforce commands. This will ensure the path matches the expected structure within the workspace/depot.
Offer for Help: I'm happy to help implement or test a fix for this issue, if some guidance on the extension’s architecture or contribution process is provided.
The text was updated successfully, but these errors were encountered:
Uh oh!
There was an error while loading. Please reload this page.
Description:
Perforce operations via the VSCode Perforce extension currently fail when performed on files that are inside the Perforce workspace but accessed via symlinks. The extension treats such files as being outside the depot, likely because it uses the symlink path rather than resolving to the actual file path in the workspace.
This is a usability issue for setups where projects are organized using symlinks (e.g., monorepos, sandboxed dev environments, shared modules, etc.).
Steps to reproduce:
Create a Perforce workspace and sync a depot.
Create a symlink pointing to a file or folder within the workspace.
Open the symlinked path in VSCode.
Try running a Perforce command (e.g., edit, diff, submit).
Expected behavior:
The extension should resolve the real path of the file (e.g., using realpath) before passing it to Perforce commands, allowing them to succeed as expected.
Actual behavior:
Commands fail, with messages indicating the file is not under Perforce control.
Suggested Fix:
Use realpath (or equivalent path resolution APIs in Node.js) to resolve symlinks before executing Perforce commands. This will ensure the path matches the expected structure within the workspace/depot.
Offer for Help: I'm happy to help implement or test a fix for this issue, if some guidance on the extension’s architecture or contribution process is provided.
The text was updated successfully, but these errors were encountered: