Skip to content

Commit

Permalink
temporarily disable MiMa check on kernel (#1925)
Browse files Browse the repository at this point in the history
* temporarily disable MiMa check on kernel

* added duration instance and queue instances to all import

* remove trailing ws

* use exceptions for kernel binary compat check

* added a TODO
  • Loading branch information
kailuowang authored Sep 28, 2017
1 parent dab28d7 commit b785cd5
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 8 deletions.
19 changes: 16 additions & 3 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,17 @@ lazy val macrosJS = macros.js

val binaryCompatibleVersion = "0.8.0"

val binaryCompatibleExceptions = {
import com.typesafe.tools.mima.core._
import com.typesafe.tools.mima.core.ProblemFilters._
Seq( //todo: remove these once we release 1.0.0-RC1
exclude[InheritedNewAbstractMethodProblem]("cats.kernel.instances.QueueInstances.*"),
exclude[InheritedNewAbstractMethodProblem]("cats.kernel.instances.QueueInstances1.*"),
exclude[InheritedNewAbstractMethodProblem]("cats.kernel.instances.QueueInstances2.*"),
exclude[InheritedNewAbstractMethodProblem]("cats.kernel.instances.DurationInstances.*")
)
}

lazy val kernel = crossProject.crossType(CrossType.Pure)
.in(file("kernel"))
.settings(moduleName := "cats-kernel", name := "Cats kernel")
Expand All @@ -242,13 +253,15 @@ lazy val kernel = crossProject.crossType(CrossType.Pure)
.settings(sourceGenerators in Compile += (sourceManaged in Compile).map(KernelBoiler.gen).taskValue)
.settings(includeGeneratedSrc)
.jsSettings(commonJsSettings)
.jvmSettings((commonJvmSettings ++
(mimaPreviousArtifacts := {
.jvmSettings(commonJvmSettings ++ Seq(
mimaPreviousArtifacts := {
if (scalaVersion.value startsWith "2.12")
Set()
else
Set("org.typelevel" %% "cats-kernel" % binaryCompatibleVersion)
})))
},
mimaBinaryIssueFilters ++= binaryCompatibleExceptions
))

lazy val kernelJVM = kernel.jvm
lazy val kernelJS = kernel.js
Expand Down
3 changes: 0 additions & 3 deletions kernel-laws/src/test/scala/cats/kernel/laws/LawTests.scala
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@ import catalysts.macros.TypeTagM

import cats.kernel.instances.all._

// these aren't included in all due to bincompat
import cats.kernel.instances.duration._
import cats.kernel.instances.queue._

import org.typelevel.discipline.{ Laws }
import org.typelevel.discipline.scalatest.Discipline
Expand Down
4 changes: 2 additions & 2 deletions kernel/src/main/scala/cats/kernel/instances/all.scala
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ trait AllInstances
with ByteInstances
with CharInstances
with DoubleInstances
// with DurationInstances // left out for bincompat
with DurationInstances
with FloatInstances
with FunctionInstances
with IntInstances
with ListInstances
with LongInstances
with MapInstances
with OptionInstances
// with QueueInstances // left out for bincompat
with QueueInstances
with SetInstances
with ShortInstances
with StreamInstances
Expand Down

0 comments on commit b785cd5

Please sign in to comment.