question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

cannot attach session when workspace is under symbolic link

See original GitHub issue

Describe the bug A clear and concise description of what the bug is.

To Reproduce Steps to reproduce the behavior:

  1. Go to ‘…’
  2. Click on ‘…’
  3. Scroll down to ‘…’
  4. See error

Do you want to fix by self? (We hope your help!)

Yes / No

(If yes,) what kind of help do you want? (e.g. Which file should I fix, Survey (related documents)

(If related)setting.json

// R.exe path for windows
"r.rterm.windows": "",

// R path for Mac OS X
"r.rterm.mac": "/usr/local/bin/R",

// R path for Linux
"r.rterm.linux": "/usr/bin/R",

// R command line options (i.e: --vanilla)
"r.rterm.option": [],

// An optional encoding to pass to R when executing the file, i.e. 'source(FILE, encoding=ENCODING)'
"r.source.encoding": "UTF-8",

// Keeping focus when running
"r.source.focus": "editor",

// Use active terminal for all commands, rather than creating a new R terminal
"r.alwaysUseActiveTerminal": false,

// Use bracketed paste mode
"r.bracketedPaste": false,

// Enable R session watcher (experimental)
"r.sessionWatcher": false,

// Delay in milliseconds before sending each line to rterm (only applies if r.bracketedPaste is false)
"r.rtermSendDelay": 8,

Expected behavior A clear and concise description of what you expected to happen.

Screenshots If applicable, add screenshots to help explain your problem. You can show the keybord contents by pressing F1 and Developer: toggle screencast mode

Environment (please complete the following information):

  • OS: [e.g. Windows, macOS, Linux]
  • VSCode Version: [e.g. 1.42.0]
  • R Version: [e.g. 3.6.2]
  • vscode-R version: [e.g. 1.2.2]

Additional context Add any other context about the problem here.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:2
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
renkun-kencommented, Oct 20, 2021

I could reproduce this. It is caused by R’s getwd() will follow the symlink, which is inconsistent with the workspace folder in vscode. We check whether the R’s working directory is consistent with the vscode workspace folder, and it is likely that multiple vscode instances are open with different workspace folders, we need to ensure that only the vscode instance with the correct workspace folder open should attach the session.

Looks like we could always follow the symlink of workspace folders on vscode side and check whether they match the R cwd.

0reactions
renkun-kencommented, Oct 20, 2021

Please try the build from #827.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Support symbolic link folders in areas like debug, extensions
The issue is that if you have a symlinked directory inside your workspace (e.g. in a git repo), git tooling no longer functions...
Read more >
How to fix: The symbolic link cannot be followed because its ...
Remote to remote symbolic links are disabled . In order to enable remote to remote symbolic links, enter the following command: C:\>fsutil ...
Read more >
Symbolic links and Network Shares - Ivanti Community
Hello, I want to know how to enable the use of symbolic links from a Citrix session with Ivanti Workspace please.
Read more >
September 2021 (version 1.61) - Visual Studio Code
One downside of using the library is that the file watcher no longer automatically detects folders in a workspace that are symbolic links...
Read more >
How to map a client COM port to a server COM port
For each COM port, a driver in the OS assigns a symbolic link name such as COM1, COM2, ... You can map client...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found