JuliaConnectoR icon indicating copy to clipboard operation
JuliaConnectoR copied to clipboard

juliaEval fails with package "Omniscape"

Open slamander opened this issue 2 years ago • 3 comments

I recognize that it is perhaps strange to open an issue here about the use of another package... But, it seems as if the basic functionality of the package Omniscape is lost when used via JuliaConnectoR. I do not have a reproducible example, but when I run a package test (Pkg.test("Omniscape")) via JuliaConnectoR, it fails all tests. Whereas, the package passes all tests when ran through Julia directly. Is it common for packages to behave differently when called through JuliaConnectoR versus Julia directly? Are there settings, perhaps pathways, which need to be configured when using some Julia packages.

slamander avatar Oct 19 '22 20:10 slamander

Could you post your commands and the output? Also, which versions of R, Julia and the package are you using? A reproducible example is really important to see. At the moment I can't imagine why there should be a different beheviour when running Pkg.test in Julia or via the JuliaConnectoR.

stefan-m-lenz avatar Oct 20 '22 14:10 stefan-m-lenz

Yes, apologies for not posting a reproducible example. I was actually able to get Omniscape working after setting the Julia binary file location using this code:

Sys.setenv(JULIA_BINDIR = "C:/Users/jbaecher/AppData/Local/Programs/Julia-1.6.3/bin")

However, before setting the location, I was still able to connect with Julia through JuliaConnectoR... The versions I am using are as follows: Julia 1.6.3; R 4.2.1; Omniscape 0.5.8; JuliaConnectoR 1.1.1. For an example, I'll provide the code for running a package test, as the error is similar.

library(JuliaConnectoR)
juliaEval('using Pkg; Pkg.add(PackageSpec(name = "Omniscape", rev = "main"))')
juliaEval('Pkg.test("Omniscape")')

I've uploaded the output here: JuliaConnectoR_pkg.test_failure_omniscape.txt After setting the binary file location, the package test was successful: JuliaConnectoR_pkg.test_success_omniscape.txt I'm now able to use JuliaConnectoR to run analyses on my own data without any trouble!

Any clarification as to what happened? I feel that understanding this will be helpful to me in the future.

slamander avatar Oct 20 '22 16:10 slamander

One possible explanation could be that you have a different version of Julia in the path, where Omniscape doesn't work. You could check the version by executing juliaEval("VERSION") one time with and one time without the JULIA_BINDIR variable and ensure that you have the same version of Julia in both cases. You can also check if you really have the same Omniscape version in both cases. It could be that you are using different Julia installations in the two cases, which also may have different checkouts of the Omniscape packages.

stefan-m-lenz avatar Oct 21 '22 16:10 stefan-m-lenz