cool-easter-32542
12/17/2023, 2:02 PM-Wunused:imports. There are two situations where I have to put unused imports into the code to make it compile with pants:
https://gitlab.com/jberkel/digero/-/blob/73381acfc27f31add7e790099fa74ed3197d75c9/core/src/main/scala/digero/ProcessXMLDump.scala
package digero
import digero.{DataFrameTask, RDDTask}
def runXMLTask(task: Task, args: TaskArguments): Unit =
…
task match
case dataframeTask: DataFrameTask[?] => …
case rdd: RDDTask[?] => …
https://gitlab.com/jberkel/digero/-/blob/73381acfc27f31add7e790099fa74ed3197d75c9/wikitext/src/main/scala/digero/wikitext/WikitextTask.scala
package digero.wikitext
import digero.wikitext.SerializationSupport
class WikitextTask extends RDDTask[RDD[(String, ParsedPage)]]:
…
override def kryoRegistrator: String = classOf[SerializationSupport].getName
In both cases the classes/traits are in the same package, so don't need the explicit import.
pantsbuild/pants