The only cause I know for errors such as this are corrupt jars. Try
cleaning the maven cache and see if the issue persists.
On 07/10/2019 17:36, Aikio, Torste wrote:
Hi,
I'm trying to build Flink 1.6.4 from source and some of the tests for
flink-scala module are failing for me. Are there some additional dependencies
that I need to install to get the tests pass? The essential part of Maven
output is here:
Running org.apache.flink.api.scala.runtime.TupleComparatorILD2Test
error: error while loading Object, Missing dependency 'object scala in
compiler mirror', required by
/usr/local/openjdk-8/jre/lib/rt.jar(java/lang/Object.class)
Tests run: 11, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.071 sec
- in org.apache.flink.api.scala.runtime.TupleComparatorILD2Test
Running org.apache.flink.api.scala.runtime.ScalaSpecialTypesSerializerTest
error: error while loading Object, Missing dependency 'object scala in
compiler mirror', required by
/usr/local/openjdk-8/jre/lib/rt.jar(java/lang/Object.class)
Tests run: 15, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.257 sec
- in org.apache.flink.api.scala.runtime.ScalaSpecialTypesSerializerTest
Running org.apache.flink.api.scala.runtime.TraversableSerializerTest
Tests run: 10, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.12 sec
- in org.apache.flink.api.scala.runtime.TraversableSerializerTest
Running org.apache.flink.api.scala.runtime.TupleSerializerTest
error: error while loading Object, Missing dependency 'object scala in
compiler mirror', required by
/usr/local/openjdk-8/jre/lib/rt.jar(java/lang/Object.class)
error: error while loading Object, Missing dependency 'object scala in
compiler mirror', required by
/usr/local/openjdk-8/jre/lib/rt.jar(java/lang/Object.class)
error: error while loading Object, Missing dependency 'object scala in
compiler mirror', required by
/usr/local/openjdk-8/jre/lib/rt.jar(java/lang/Object.class)
Tests run: 5, Failures: 0, Errors: 5, Skipped: 0, Time elapsed: 2.245 sec
<<< FAILURE! - in
org.apache.flink.api.scala.typeutils.EnumValueSerializerUpgradeTest
checkIdenticalEnums(org.apache.flink.api.scala.typeutils.EnumValueSerializerUpgradeTest)
Time elapsed: 1.464 sec <<< ERROR!
scala.reflect.internal.MissingRequirementError: object scala in compiler
mirror not found.
at
scala.reflect.internal.MissingRequirementError$.signal(MissingRequirementError.scala:17)
at
scala.reflect.internal.MissingRequirementError$.notFound(MissingRequirementError.scala:18)
at
scala.reflect.internal.Mirrors$RootsBase.getModuleOrClass(Mirrors.scala:53)
at
scala.reflect.internal.Mirrors$RootsBase.getModuleOrClass(Mirrors.scala:66)
at
scala.reflect.internal.Mirrors$RootsBase.getPackage(Mirrors.scala:173)
at
scala.reflect.internal.Definitions$DefinitionsClass.ScalaPackage$lzycompute(Definitions.scala:161)
at
scala.reflect.internal.Definitions$DefinitionsClass.ScalaPackage(Definitions.scala:161)
at
scala.reflect.internal.Definitions$DefinitionsClass.ScalaPackageClass$lzycompute(Definitions.scala:162)
at
scala.reflect.internal.Definitions$DefinitionsClass.ScalaPackageClass(Definitions.scala:162)
at
scala.reflect.internal.Definitions$DefinitionsClass.init(Definitions.scala:1391)
at scala.tools.nsc.Global$Run.<init>(Global.scala:1242)
at
org.apache.flink.api.scala.typeutils.EnumValueSerializerUpgradeTest$.compileScalaFile(EnumValueSerializerUpgradeTest.scala:207)
at
org.apache.flink.api.scala.typeutils.EnumValueSerializerUpgradeTest$.compileAndLoadEnum(EnumValueSerializerUpgradeTest.scala:161)
at
org.apache.flink.api.scala.typeutils.EnumValueSerializerUpgradeTest.checkCompatibility(EnumValueSerializerUpgradeTest.scala:128)
at
org.apache.flink.api.scala.typeutils.EnumValueSerializerUpgradeTest.checkIdenticalEnums(EnumValueSerializerUpgradeTest.scala:87)
The Maven command used for the build is
./apache-maven-3.2.5/bin/mvn -s /m2/settings.xml -B deploy -Pdocs-and-source
-Prelease -Dgpg.skip=true -Pinclude-kinesis
-DaltDeploymentRepository=internal-releases::default::https://<internal>/nexus/content/repositories/releases/
I'm running the build inside "openjdk:8" Docker image (which is based on Debian
9) with Maven 3.2.5 downloaded from Apache archives. The image has OpenJDK version
1.8.0_222-b10 installed.
I realize that I can just skip tests with Maven but I'd prefer not to if there
is a way to get them pass. Any help would be most welcome.
/Torste Aikio