From e3a2bef8f9d8dd6af3f3a7b42fd03ed05c9aeb64 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=98yvind=20Raddum=20Berg?= Date: Tue, 28 Apr 2020 23:29:21 +0200 Subject: [PATCH] Use shaded circe 0.13.0 --- .../converter/internal/importer/ConversionOptions.scala | 4 ++-- .../converter/internal/importer/FacadeJson.scala | 4 ++-- .../internal/importer/ScalaJsBundlerDepFile.scala | 6 +++--- .../converter/internal/importer/documentation/Npmjs.scala | 4 ++-- .../converter/internal/importer/jsonCodecs.scala | 4 ++-- .../converter/internal/importer/Summary.scala | 6 +++--- .../internal/importer/build/BinTrayPublisher.scala | 2 +- .../converter/internal/importer/JsonTests.scala | 2 +- .../internal/importer/ScalaJsBundlerDepTest.scala | 4 ++-- project/Deps.scala | 2 +- .../scalablytyped/converter/internal/ImportTypings.scala | 6 +++--- .../scalablytyped/converter/internal/scalajs/Dep.scala | 6 +++--- .../internal/scalajs/flavours/SlinkyTagsLoader.scala | 8 ++++---- .../scala/org/scalablytyped/converter/internal/Json.scala | 6 +++--- 14 files changed, 32 insertions(+), 32 deletions(-) diff --git a/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/ConversionOptions.scala b/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/ConversionOptions.scala index 9fe8872c21..73d9b0efb7 100644 --- a/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/ConversionOptions.scala +++ b/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/ConversionOptions.scala @@ -2,7 +2,7 @@ package org.scalablytyped.converter package internal package importer -import io.circe.{Decoder, Encoder} +import io.circe013.{Decoder, Encoder} import org.scalablytyped.converter.internal.scalajs.{Name, Versions} case class ConversionOptions( @@ -19,7 +19,7 @@ case class ConversionOptions( ) object ConversionOptions { - import io.circe.generic.auto._ + import io.circe013.generic.auto._ import jsonCodecs._ implicit val encodes: Encoder[ConversionOptions] = exportEncoder[ConversionOptions].instance diff --git a/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/FacadeJson.scala b/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/FacadeJson.scala index 77d8e86afd..fad3af9d3d 100644 --- a/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/FacadeJson.scala +++ b/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/FacadeJson.scala @@ -1,8 +1,8 @@ package org.scalablytyped.converter.internal package importer -import io.circe.Decoder -import io.circe.generic.semiauto.deriveDecoder +import io.circe013.Decoder +import io.circe013.generic.semiauto.deriveDecoder import org.scalablytyped.converter.internal.scalajs.Dep final case class FacadeJson(typings: Set[String], dependencies: Set[Dep.ScalaJs]) diff --git a/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/ScalaJsBundlerDepFile.scala b/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/ScalaJsBundlerDepFile.scala index 259ffc92d9..56d9e81793 100644 --- a/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/ScalaJsBundlerDepFile.scala +++ b/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/ScalaJsBundlerDepFile.scala @@ -2,9 +2,9 @@ package org.scalablytyped.converter.internal package importer import org.scalablytyped.converter.internal.ts.TsIdentLibrary -import io.circe.generic.semiauto.{deriveDecoder, deriveEncoder} -import io.circe.{Decoder, Encoder} -import io.circe.syntax._ +import io.circe013.generic.semiauto.{deriveDecoder, deriveEncoder} +import io.circe013.{Decoder, Encoder} +import io.circe013.syntax._ object ScalaJsBundlerDepFile { diff --git a/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/documentation/Npmjs.scala b/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/documentation/Npmjs.scala index 370fb2a2f2..6130ff7df5 100644 --- a/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/documentation/Npmjs.scala +++ b/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/documentation/Npmjs.scala @@ -2,8 +2,8 @@ package org.scalablytyped.converter.internal package importer.documentation import com.olvind.logging.Logger -import io.circe.generic.semiauto.{deriveDecoder, deriveEncoder} -import io.circe.{Decoder, Encoder} +import io.circe013.generic.semiauto.{deriveDecoder, deriveEncoder} +import io.circe013.{Decoder, Encoder} import org.scalablytyped.converter.internal.importer.Source import scala.concurrent.Future diff --git a/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/jsonCodecs.scala b/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/jsonCodecs.scala index d3cc4ba65a..fba261638f 100644 --- a/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/jsonCodecs.scala +++ b/importer-portable/src/main/scala/org/scalablytyped/converter/internal/importer/jsonCodecs.scala @@ -5,7 +5,7 @@ import java.io.File import java.net.URI import org.scalablytyped.converter.internal.ts._ -import io.circe._ +import io.circe013._ object jsonCodecs { implicit def IArrayEncoder[T <: AnyRef: Encoder]: Encoder[IArray[T]] = @@ -31,7 +31,7 @@ object jsonCodecs { implicit val TsIdentLibraryMapEncoder: Encoder[Map[TsIdentLibrary, String]] = Encoder[Map[String, String]].contramap[Map[TsIdentLibrary, String]](_.map { case (k, v) => k.value -> v }) - import io.circe.generic.semiauto._ + import io.circe013.generic.semiauto._ implicit val CompilerOptionsEncoder: Encoder[CompilerOptions] = deriveEncoder[CompilerOptions] implicit val CompilerOptionsDecoder: Decoder[CompilerOptions] = deriveDecoder[CompilerOptions] diff --git a/importer/src/main/scala/org/scalablytyped/converter/internal/importer/Summary.scala b/importer/src/main/scala/org/scalablytyped/converter/internal/importer/Summary.scala index 513a231623..856930e086 100644 --- a/importer/src/main/scala/org/scalablytyped/converter/internal/importer/Summary.scala +++ b/importer/src/main/scala/org/scalablytyped/converter/internal/importer/Summary.scala @@ -2,9 +2,9 @@ package org.scalablytyped.converter.internal package importer import org.scalablytyped.converter.internal.ts.TsIdentLibrary -import io.circe.Decoder.Result -import io.circe.generic.semiauto.{deriveDecoder, deriveEncoder} -import io.circe.{Decoder, Encoder, HCursor} +import io.circe013.Decoder.Result +import io.circe013.generic.semiauto.{deriveDecoder, deriveEncoder} +import io.circe013.{Decoder, Encoder, HCursor} case class Summary( successes: Set[TsIdentLibrary], diff --git a/importer/src/main/scala/org/scalablytyped/converter/internal/importer/build/BinTrayPublisher.scala b/importer/src/main/scala/org/scalablytyped/converter/internal/importer/build/BinTrayPublisher.scala index 98c99358a0..6858b6451e 100644 --- a/importer/src/main/scala/org/scalablytyped/converter/internal/importer/build/BinTrayPublisher.scala +++ b/importer/src/main/scala/org/scalablytyped/converter/internal/importer/build/BinTrayPublisher.scala @@ -11,7 +11,7 @@ import com.ning.http.client._ import com.ning.http.client.listenable.AbstractListenableFuture import dispatch.{FunctionHandler, Http, StatusCode} import gigahorse.Status -import io.circe.{Decoder, Encoder} +import io.circe013.{Decoder, Encoder} import org.scalablytyped.converter.internal.scalajs.Dep import org.scalablytyped.converter.internal.stringUtils.quote diff --git a/importer/src/test/scala/org/scalablytyped/converter/internal/importer/JsonTests.scala b/importer/src/test/scala/org/scalablytyped/converter/internal/importer/JsonTests.scala index 2521247242..c4c44573bd 100644 --- a/importer/src/test/scala/org/scalablytyped/converter/internal/importer/JsonTests.scala +++ b/importer/src/test/scala/org/scalablytyped/converter/internal/importer/JsonTests.scala @@ -1,6 +1,6 @@ package org.scalablytyped.converter.internal.importer -import io.circe.parser._ +import io.circe013.parser._ import org.scalablytyped.converter.internal.IArray import org.scalablytyped.converter.internal.importer.jsonCodecs._ import org.scalablytyped.converter.internal.ts._ diff --git a/importer/src/test/scala/org/scalablytyped/converter/internal/importer/ScalaJsBundlerDepTest.scala b/importer/src/test/scala/org/scalablytyped/converter/internal/importer/ScalaJsBundlerDepTest.scala index 18bc14038b..bec6baf80e 100644 --- a/importer/src/test/scala/org/scalablytyped/converter/internal/importer/ScalaJsBundlerDepTest.scala +++ b/importer/src/test/scala/org/scalablytyped/converter/internal/importer/ScalaJsBundlerDepTest.scala @@ -1,7 +1,7 @@ package org.scalablytyped.converter.internal.importer -import io.circe.parser._ -import io.circe.syntax._ +import io.circe013.parser._ +import io.circe013.syntax._ import org.scalablytyped.converter.internal.importer.ScalaJsBundlerDepFile.NpmDependencies import org.scalatest.funsuite.AnyFunSuite diff --git a/project/Deps.scala b/project/Deps.scala index 68dec36016..1faa4a4476 100644 --- a/project/Deps.scala +++ b/project/Deps.scala @@ -14,5 +14,5 @@ object Deps { val scopt = "com.github.scopt" %% "scopt" % "4.0.0-RC2" val circe: Seq[ModuleID] = - Seq("core", "generic", "parser", "jackson29").map(s => "io.circe" %% s"circe-$s" % "0.11.1") + Seq("core", "generic", "parser", "jackson29").map(s => "io.circe013" %% s"circe-$s" % "0.13.0") } diff --git a/sbt-converter06/src/main/scala/org/scalablytyped/converter/internal/ImportTypings.scala b/sbt-converter06/src/main/scala/org/scalablytyped/converter/internal/ImportTypings.scala index d4170c3ca2..552da66588 100644 --- a/sbt-converter06/src/main/scala/org/scalablytyped/converter/internal/ImportTypings.scala +++ b/sbt-converter06/src/main/scala/org/scalablytyped/converter/internal/ImportTypings.scala @@ -4,7 +4,7 @@ package internal import java.nio.file.Path import com.olvind.logging.Logger -import io.circe.{Decoder, Encoder} +import io.circe013.{Decoder, Encoder} import org.scalablytyped.converter.internal.importer._ import org.scalablytyped.converter.internal.importer.build.{Compiler, PublishedSbtProject} import org.scalablytyped.converter.internal.importer.documentation.Npmjs @@ -27,7 +27,7 @@ object ImportTypings { ) object Input { - import io.circe.generic.auto._ + import io.circe013.generic.auto._ import jsonCodecs._ implicit val InputEncoder: Encoder[Input] = exportEncoder[Input].instance @@ -37,7 +37,7 @@ object ImportTypings { case class Output(deps: Set[Dep], allJars: Set[os.Path]) object Output { - import io.circe.generic.auto._ + import io.circe013.generic.auto._ import jsonCodecs._ implicit val OutputEncoder: Encoder[Output] = exportEncoder[Output].instance implicit val OutputDecoder: Decoder[Output] = exportDecoder[Output].instance diff --git a/scalajs/src/main/scala/org/scalablytyped/converter/internal/scalajs/Dep.scala b/scalajs/src/main/scala/org/scalablytyped/converter/internal/scalajs/Dep.scala index d5f98ebb37..406e187208 100644 --- a/scalajs/src/main/scala/org/scalablytyped/converter/internal/scalajs/Dep.scala +++ b/scalajs/src/main/scala/org/scalablytyped/converter/internal/scalajs/Dep.scala @@ -1,6 +1,6 @@ package org.scalablytyped.converter.internal.scalajs -import io.circe.{Decoder, Encoder} +import io.circe013.{Decoder, Encoder} import org.scalablytyped.converter.internal.stringUtils.quote import scala.xml.Elem @@ -61,6 +61,6 @@ object Dep { case class ScalaFullVersion(org: String, artifact: String, version: String) extends Dep case class ScalaJs(org: String, artifact: String, version: String) extends Dep - implicit val DepDecoder: Decoder[Dep] = io.circe.generic.semiauto.deriveDecoder[Dep] - implicit val DepEncoder: Encoder[Dep] = io.circe.generic.semiauto.deriveEncoder[Dep] + implicit val DepDecoder: Decoder[Dep] = io.circe013.generic.semiauto.deriveDecoder[Dep] + implicit val DepEncoder: Encoder[Dep] = io.circe013.generic.semiauto.deriveEncoder[Dep] } diff --git a/scalajs/src/main/scala/org/scalablytyped/converter/internal/scalajs/flavours/SlinkyTagsLoader.scala b/scalajs/src/main/scala/org/scalablytyped/converter/internal/scalajs/flavours/SlinkyTagsLoader.scala index 3a2e97924e..d166d989c9 100644 --- a/scalajs/src/main/scala/org/scalablytyped/converter/internal/scalajs/flavours/SlinkyTagsLoader.scala +++ b/scalajs/src/main/scala/org/scalablytyped/converter/internal/scalajs/flavours/SlinkyTagsLoader.scala @@ -2,7 +2,7 @@ package org.scalablytyped.converter.internal package scalajs package flavours -import io.circe.Decoder +import io.circe013.Decoder import org.scalablytyped.converter.internal.scalajs.QualifiedName.StdNames import org.scalablytyped.converter.internal.scalajs.flavours.GenSlinkyComponents.names.{ AnyHtmlElement, @@ -154,9 +154,9 @@ object SlinkyTagsLoader { /* extract what we need from the slinky json files */ type AttrsByTag = Map[TagName.Concrete, (Tag, Set[String])] object AttrsByTag { - private implicit val TagDecoder: Decoder[Tag] = io.circe.generic.semiauto.deriveDecoder[Tag] - private implicit val AttributeDecoder: Decoder[Attribute] = io.circe.generic.semiauto.deriveDecoder[Attribute] - private implicit val TagsModelDecoder: Decoder[TagsModel] = io.circe.generic.semiauto.deriveDecoder[TagsModel] + private implicit val TagDecoder: Decoder[Tag] = io.circe013.generic.semiauto.deriveDecoder[Tag] + private implicit val AttributeDecoder: Decoder[Attribute] = io.circe013.generic.semiauto.deriveDecoder[Attribute] + private implicit val TagsModelDecoder: Decoder[TagsModel] = io.circe013.generic.semiauto.deriveDecoder[TagsModel] private def massage(model: TagsModel): AttrsByTag = model.tags.map { tag => diff --git a/utils/src/main/scala/org/scalablytyped/converter/internal/Json.scala b/utils/src/main/scala/org/scalablytyped/converter/internal/Json.scala index 89a1d860b8..013bb33a5e 100644 --- a/utils/src/main/scala/org/scalablytyped/converter/internal/Json.scala +++ b/utils/src/main/scala/org/scalablytyped/converter/internal/Json.scala @@ -4,8 +4,8 @@ import java.io.File import java.nio.file.{Files, Path} import cats.data.ValidatedNel -import io.circe._ -import io.circe.syntax._ +import io.circe013._ +import io.circe013.syntax._ import scala.io.Source import scala.util.control.NonFatal @@ -18,7 +18,7 @@ object Json { object CustomJacksonParser extends Parser { import com.fasterxml.jackson.core.{JsonFactory, JsonParser} import com.fasterxml.jackson.databind.ObjectMapper - import io.circe.jackson.CirceJsonModule + import io.circe013.jackson.CirceJsonModule // val Features = Set[JsonReadFeature]( // JsonReadFeature.ALLOW_JAVA_COMMENTS,