Issues with setting up `rJava` in Github actions for package checking
Entering edit mode
aravind-j ▴ 20
Last seen 17 days ago

I am trying to use github actions for package checking adapted from biocthis for my package rmelting.

I am having issues with macOS and windows for both r-devel 4.1.0 (BioC 3.13) and r-release 4.0.4 (BioC 3.12).

All the builds are failing with the following message in both macOS and windows.

ERROR: dependency ‘rJava’ is not available for package ‘rmelting’

Bioconductor machines are testing successfully with a modification according to .BBSoptions.

# The reason this package is marked as unsupported on win32 is that
# it requires the Java JDK. However it seems that Oracle no longer
# provides the JDK for 32-bit windows:
UnsupportedPlatforms: win32

I have tried the following fixes with no success.

  • Adding actions/setup-java@v1 to the yml file.
  • For windows, tried "--no-multiarch" option for both installing rJava and rmelting.

How to setup rJava properly for all these platforms ?

github-actions biocthis rJava • 145 views
Entering edit mode
Last seen 11 days ago
United States


One option you can try is to check all the packages that depend on rJava (the green ones are from Bioconductor) at and see if any of them have a working GitHub Actions workflow. I don't use rJava directly in my packages, so I'm not really familiar with any of those packages. I clicked on a few but didn't find GHA workflows.

Another simpler option you can try is to disable the windows and macOS tests on the biocthis-inspired GHA workflow you have. That is, use GHA to get quick information on how your package is working on the Bioconductor dockers, and rely on the BBS system for checks on macOS and windows.

The harder option is to figure out how to install rJava in each of those OSes. I've done similar things myself for other packages.

Best, Leo

Entering edit mode

I did check all the packages that depend on rJava as suggested, but could not find any with GHA workflows for macOS and windows.

Right now I have disabled the windows and macOS tests in the GHA workflow.

Entering edit mode
Mike Smith ★ 4.9k
Last seen 23 hours ago
EMBL Heidelberg / de.NBI

I've not tried installing rJava on a GitHub runner before. Looking at the GHA logs the error on installation of rJava is:

configure: error: Unable to run a simple JNI program. Make sure you have configured R with Java support (see R documentation) and check config.log for failure reason. ERROR: configuration failed for package ‘rJava’

Does running R CMD javareconf after you've installed Java on the system, but before you try installing the package, make a difference?

Entering edit mode

For linux, R CMD javareconf does work, but not for windows and macOS.


Login before adding your answer.

Traffic: 486 users visited in the last hour
Help About
Access RSS

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6