vscode-R icon indicating copy to clipboard operation
vscode-R copied to clipboard

Run command in Terminal errors with "Cannot read properties of undefined (reading 'replace')"

Open kassi opened this issue 1 year ago • 0 comments

Describe the bug Unable to run any code / file in R terminal. Always getting an error dialog:

Command 'R: Run Command in Terminal' resulted in an error Cannot read properties of undefined (reading 'split')

or when executing "R: Run command with editor path in terminal"

** Command 'R: Run Command With Editor Path in Terminal' resulted in an error** Cannot read properties of undefined (reading 'replace')

To Reproduce Steps to reproduce the behavior:

  1. Install R via homebrew brew install r
  2. Install R extension from REditorSupport
  3. Open R file
  4. Execute "R: Create R terminal"
  5. Execute "R: Run command in terminal"

Can you fix this issue by yourself? (We appreciate the help)

No

setting.json

// R path for Mac OS X
"r.rpath.mac": "/opt/homebrew/bin/R",

Expected behavior Program is run in R terminal.

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

Environment (please complete the following information):

  • OS: macOS 14.4
  • VSCode Version: 1.89.1
  • R Version: 4.4.0
  • vscode-R version: 2.8.4

Additional context

kassi avatar May 23 '24 14:05 kassi