Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Segfault when loading R units package in a task #431

Open
ianfiske opened this issue Aug 24, 2021 · 2 comments
Open

Segfault when loading R units package in a task #431

ianfiske opened this issue Aug 24, 2021 · 2 comments

Comments

@ianfiske
Copy link

ianfiske commented Aug 24, 2021

If I load the R package units within a julia task, then Julia crashes with a segfault.

using RCall

@async begin
   R"library(units)"
end

then Julia crashes with a segfault error. See julia-vscode/julia-vscode#2299 for a bit of background and in particular https://gist.github.com/ianfiske/c18cc4c2dd64f45922b40a7c7f536732 for the lldb stacktrace.

I am on Julia 1.6.2, OSX 11.4, R 4.1.0, RCall 0.13.12.

This issue manifests by crashing within VSCode since the Julia extension there uses tasks (I think).

(Update: Initially this was reported as triggered by the R package sf, but the underlying crash is actually from loading units, a dependency package of sf).

@ianfiske ianfiske changed the title Segfault when loading R sf package in a task Segfault when loading R units package in a task Aug 24, 2021
@alunap
Copy link

alunap commented Sep 2, 2022

Was there ever an answer to this? I also get the segfault trying to load any R library in VSCode via RCall. Not just sf, though, I get a crash with tidyverse or arrow or anything else. I tried setting R_HOME and recompiling RCall, but that didn't help. I am on an intel iMac running Monterey 12.5. Julia v1.8.0, R v4.2.0. First time I've tried using RCall, although I use PyCall all the time successfully.
Correction: digging around I saw the R installed by anaconda was in my .zshenv LD_LIBRARY_PATH. When I removed that, I could load tidyverse and arrow, but sf fails in the same way.

@simonbyrne
Copy link
Member

I suspect it's #444: I don't have the time to do this, but am happy to review if someone else wants to take it on.

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

No branches or pull requests

3 participants