Skip to content

Install prerequisites into the user library when the default is read-only - #1912

Open
Don-Yin wants to merge 1 commit into
REditorSupport:mainfrom
Don-Yin:fix-user-library
Open

Don-Yin wants to merge 1 commit into
REditorSupport:mainfrom
Don-Yin:fix-user-library

Conversation

@Don-Yin

@Don-Yin Don-Yin commented Oct 26, 2026

Copy link
Copy Markdown

Fixes #1516.

I reproduced this with a read-only default library and no user library: accepting the prompt to install languageserver failed with unable to install packages. I changed the prerequisite installer to create R_LIBS_USER only when the default library isn't writable, and pass it explicitly to install.packages().

node repro.cjs before and after the change

I left sess unchanged: install_sess.R now requires VSCODE_R_SESS_LIBRARY, so the fallback linked in the issue is no longer there to share.

I added one focused test. It fails on main and passes with the change, and the utility/installer tests, lint, formatting, typecheck and production build pass locally.

…only

Fixes REditorSupport#1516

Signed-off-by: Don Yin <Don_Yin@outlook.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Installing required packages fails if the system library is not writable and the user has no library

1 participant