我正在尝试在本地运行和测试 amazon deequ 库,但对于各种示例,我反复收到类未找到错误。准确错误
java.lang.NoClassDefFoundError: scala/Product$class
at com.amazon.deequ.profiles.ColumnProfilerRunBuilderFileOutputOptions.<init>(ColumnProfilerRunner.scala:31)
at com.amazon.deequ.profiles.ColumnProfilerRunBuilder.run(ColumnProfilerRunBuilder.scala:174)
... 47 elided
Caused by: java.lang.ClassNotFoundException: scala.Product$class
at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:466)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:566)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:499)
... 49 more
或者
val suggestionResult = ConstraintSuggestionRunner().onData(input).addConstraintRules(Rules.DEFAULT).run()
java.lang.NoClassDefFoundError: scala/Product$class
at com.amazon.deequ.suggestions.rules.CompleteIfCompleteRule.<init>(CompleteIfCompleteRule.scala:25)
at com.amazon.deequ.suggestions.Rules$.<init>(ConstraintSuggestionRunner.scala:33)
at com.amazon.deequ.suggestions.Rules$.<clinit>(ConstraintSuggestionRunner.scala)
... 49 elided
我遵循的代码是我使用 spark-submit --class --packages com.amazon.deequ:deequ:1.0.4 的示例中给出的代码
我也尝试使用 spark-shell --jars 并尝试逐行运行但仍然得到相同的结果