Hi all, just to inform you about a quirk we encountered when trying to compile, i.e. test dataverse (v5.14) on our systems. If you call "mvn package" on (linux) systems that don't contain any hostname except localhost in the /etc/hosts file the tests fail because of a call to java.net.InetAdress.getLocalHost(). The method throws an exception which is caught and "null" is returned from getDataverseSiteUrlStatic(). In "DatasetVersion.java" the return value is used e.g. in line 2016 ".add("url", SystemConfig.getDataverseSiteUrlStatic())" and leads to a failure. This is only the case for the tests, compiling only works fine. We use (Open)Suse so not an officially supported system. We just thought it might be good to let you know in case anybody else stumbles across.
Huh. Very interesting! Thanks for letting us know! If you'd like to add a note about this to our guides, please go ahead! We have some quick fix instructions here: https://guides.dataverse.org/en/6.0/developers/documentation.html#quick-fix
Actually could you create an issue for this @Björn Selent ? Sounds like something we need to catch and also add a test for
OK, will do that
Thanks for opening this: maven test run fails on OpenSuse #9947
Last updated: Oct 30 2025 at 06:21 UTC