Run command in Terminal errors with "Cannot read properties of undefined (reading 'replace')"
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:
- Install R via homebrew
brew install r - Install R extension from REditorSupport
- Open R file
- Execute "R: Create R terminal"
- 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