Akka Serverless Scala SDK Compiler doesn't process ScalaC 2.13 options

I just updated the Akka Serverless Java/Scala SDK to version 0.9.0 and started getting compilation errors from the from the codegen portion of the SDK. We are modifying our scalacOptions like this:

scalacOptions ++= (if(scalaVersion.value.startsWith("3")) scala3Options else scalac2Options),

(note: we are using Scala 2.13.5)

We get this kind of output from the code generator:
[error] bad option: ‘-Wunused:imports’

which happens for -target:11 and '-Wdeadcode` and probably all the others before it fails with this exception:

java.lang.IllegalArgumentException: Nothing to generate!
at com.lightbend.akkasls.codegen.SourceGeneratorUtils$.mainPackageName(SourceGeneratorUtils.scala:51)
at com.akkaserverless.codegen.scalasdk.impl.MainSourceGenerator$.akkaServerlessFactorySource(MainSourceGenerator.scala:121)
at com.akkaserverless.codegen.scalasdk.impl.MainSourceGenerator$.generateManaged(MainSourceGenerator.scala:37)
at com.akkaserverless.codegen.scalasdk.impl.SourceGenerator$.generateManaged(SourceGenerator.scala:28)
at com.akkaserverless.codegen.scalasdk.AkkaserverlessGenerator$.process(AkkaserverlessGenerator.scala:43)
at protocgen.CodeGenApp.run(CodeGenApp.scala:46)
at protocgen.CodeGenApp.run$(CodeGenApp.scala:39)
at com.akkaserverless.codegen.scalasdk.AkkaserverlessGenerator$.run(AkkaserverlessGenerator.scala:28)
at protocgen.CodeGenApp.run(CodeGenApp.scala:31)
at protocgen.CodeGenApp.run$(CodeGenApp.scala:30)
at com.akkaserverless.codegen.scalasdk.AkkaserverlessGenerator$.run(AkkaserverlessGenerator.scala:28)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at protocbridge.SandboxedJvmGenerator$$anon$1.run(Generator.scala:119)
at protocbridge.frontend.PluginFrontend$.$anonfun$runWithBytes$1(PluginFrontend.scala:52)
at scala.util.Try$.apply(Try.scala:213)
at protocbridge.frontend.PluginFrontend$.runWithBytes(PluginFrontend.scala:52)
at protocbridge.frontend.PluginFrontend$.runWithInputStream(PluginFrontend.scala:122)
at protocbridge.frontend.PosixPluginFrontend$.$anonfun$prepare$2(PosixPluginFrontend.scala:39)
at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.java:23)
at scala.concurrent.impl.ExecutionContextImpl$DefaultThreadFactory$$anon$1$$anon$2.block(ExecutionContextImpl.scala:75)
at java.base/java.util.concurrent.ForkJoinPool.managedBlock(ForkJoinPool.java:3118)
at scala.concurrent.impl.ExecutionContextImpl$DefaultThreadFactory$$anon$1.blockOn(ExecutionContextImpl.scala:87)
at scala.concurrent.package$.blocking(package.scala:146)
at protocbridge.frontend.PosixPluginFrontend$.$anonfun$prepare$1(PosixPluginFrontend.scala:37)
at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.java:23)
at scala.concurrent.Future$.$anonfun$apply$1(Future.scala:659)
at scala.util.Success.$anonfun$map$1(Try.scala:255)
at scala.util.Success.map(Try.scala:213)
at scala.concurrent.Future.$anonfun$map$1(Future.scala:292)
at scala.concurrent.impl.Promise.liftedTree1$1(Promise.scala:33)
at scala.concurrent.impl.Promise.$anonfun$transform$1(Promise.scala:33)
at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:64)
at java.base/java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1426)
at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1020)
at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1656)
at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1594)
at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:183)
–jvm_3_out: Nothing to generate!

I’m trying to decide if I’m doing something wrong in SBT build.sbt or if I should log an issue against the SDK.

This problem went away when I removed some plugins that were, apparently, colliding with AkkaServerlessPlugin. ScalaFmt in particular.