The Scala team advises in their Long-term compatibility plans for Scala 3 to use a Scala LTS version for libraries:
The Scala LTS line is advised to be used for publishing libraries.
Almost all libraries I use adhere to this. The latest version of oidc4s depends on Scala 3.7, which also forces users of the library to use (at least) Scala 3.7. If I have a code base on Scala 3.3, then I will get all kinds of strange errors with oidc4s 0.13.5 as a dependency, even if I don't import it anywhere. Please consider depending on the latest LTS version instead (3.3.x) - or mention in the readme that it can only be used when on the newest Scala 3 release (though that wouldn't have helped me).
Some examples of error messages that I got, just in case someone is searching for them:
package scala.compiletime does not have a member method summonFrom
package scala.compiletime does not have a member method erasedValue
[error] error while loading Mirror,
[error] class file scala/deriving/Mirror.class is broken (version 52.0),
[error] please check the JDK compatibility of your Scala version (3.3.6),
[error] reading aborted with class dotty.tools.tasty.UnpickleException:
[error] TASTy signature has wrong version.
[error] expected: {majorVersion: 28, minorVersion: 3}
[error] found : {majorVersion: 28, minorVersion: 7}
[error]
[error] This TASTy file was produced by a more recent, forwards incompatible release.
[error] To read this TASTy file, please upgrade your tooling.
[error] The TASTy file was produced by Scala 3.7.4-bin-nonbootstrapped.
[error] ## Exception when compiling 199 sources to /home/peter.poschmann/Development/detact-streams/common/target/scala-3.3.6/classes
[error] java.lang.AssertionError: assertion failed: module class Whatever$ has non-class parent: TypeRef(ThisType(TypeRef(TermRef(ThisType(TypeRef(NoPrefix,module class scala)),object deriving),Mirror$)),Singleton)
[error] scala.runtime.Scala3RunTime$.assertFailed(Scala3RunTime.scala:8)
[error] dotty.tools.dotc.core.SymDenotations$ClassDenotation.traverse$1(SymDenotations.scala:1993)
[error] dotty.tools.dotc.core.SymDenotations$ClassDenotation.computeBaseData(SymDenotations.scala:1998)
[error] dotty.tools.dotc.core.SymDenotations$BaseDataImpl.apply(SymDenotations.scala:2987)
[error] dotty.tools.dotc.core.SymDenotations$ClassDenotation.baseData(SymDenotations.scala:1964)
[error] dotty.tools.dotc.core.SymDenotations$ClassDenotation.baseClassSet(SymDenotations.scala:1980)
[error] dotty.tools.dotc.core.SymDenotations$ClassDenotation.derivesFrom(SymDenotations.scala:2006)
[error] dotty.tools.dotc.core.Types$Type.loop$1(Types.scala:280)
[error] dotty.tools.dotc.core.Types$Type.derivesFrom(Types.scala:304)
[error] dotty.tools.dotc.core.TypeUtils.isGenericTuple(TypeUtils.scala:78)
[error] dotty.tools.dotc.core.TypeUtils.genericTupleArityCompare(TypeUtils.scala:96)
[error] dotty.tools.dotc.core.TypeUtils.isSmallGenericTuple(TypeUtils.scala:85)
[error] dotty.tools.dotc.typer.Typer.trySmallGenericTuple$1(Typer.scala:730)
[error] dotty.tools.dotc.typer.Typer.typedSelectWithAdapt(Typer.scala:793)
...
The Scala team advises in their Long-term compatibility plans for Scala 3 to use a Scala LTS version for libraries:
Almost all libraries I use adhere to this. The latest version of oidc4s depends on Scala 3.7, which also forces users of the library to use (at least) Scala 3.7. If I have a code base on Scala 3.3, then I will get all kinds of strange errors with oidc4s 0.13.5 as a dependency, even if I don't import it anywhere. Please consider depending on the latest LTS version instead (3.3.x) - or mention in the readme that it can only be used when on the newest Scala 3 release (though that wouldn't have helped me).
Some examples of error messages that I got, just in case someone is searching for them: