Skip to content

Commit

Permalink
Merge pull request #159 from nulab/BLG_INTG-1621/bump-up-cats-version
Browse files Browse the repository at this point in the history
Blg intg 1621/bump up cats version
  • Loading branch information
jtakakura authored Jul 12, 2024
2 parents 4199917 + cc2163e commit 5ef6a35
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 11 deletions.
3 changes: 1 addition & 2 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,14 @@ lazy val commonSettings = Seq(
"-Ywarn-unused"
),
libraryDependencies ++= {
val catsVersion = "2.1.1"
val catsVersion = "2.8.0"
val monixVersion = "3.2.2"
val doobieVersion = "0.9.0"
val akkaVersion = "2.6.17"
val akkaHttpVersion = "10.2.7"
Seq(
"org.typelevel" %% "cats-core" % catsVersion,
"org.typelevel" %% "cats-kernel" % catsVersion,
"org.typelevel" %% "cats-macros" % catsVersion,
"io.monix" %% "monix" % monixVersion,
"io.monix" %% "monix-eval" % monixVersion,
"io.monix" %% "monix-reactive" % monixVersion,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@ package com.nulabinc.backlog.migration.common.services

import java.nio.file.Path

import cats.Foldable.ops._
import cats.Monad
import cats.Monad.ops._
import cats.data.Validated.{Invalid, Valid}
import cats.syntax.flatMap._
import cats.syntax.foldable._
import cats.syntax.functor._
import com.nulabinc.backlog.migration.common.codec.{PriorityMappingDecoder, PriorityMappingEncoder}
import com.nulabinc.backlog.migration.common.domain.mappings._
import com.nulabinc.backlog.migration.common.dsl.{ConsoleDSL, StorageDSL}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package com.nulabinc.backlog.migration.common.services

import cats.Monad.ops._
import cats.syntax.flatMap._
import cats.syntax.functor._
import cats.{Applicative, Monad}
import com.nulabinc.backlog.migration.common.codec.Decoder
import com.nulabinc.backlog.migration.common.dsl.{ConsoleDSL, HttpDSL, HttpError, HttpQuery}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@ package com.nulabinc.backlog.migration.common.services

import java.nio.file.Path

import cats.Foldable.ops._
import cats.Monad
import cats.Monad.ops._
import cats.data.Validated.{Invalid, Valid}
import cats.syntax.flatMap._
import cats.syntax.foldable._
import cats.syntax.functor._
import com.nulabinc.backlog.migration.common.codec.{StatusMappingDecoder, StatusMappingEncoder}
import com.nulabinc.backlog.migration.common.domain.BacklogStatuses
import com.nulabinc.backlog.migration.common.domain.mappings._
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@ package com.nulabinc.backlog.migration.common.services

import java.nio.file.Path

import cats.Foldable.ops._
import cats.Monad
import cats.Monad.ops._
import cats.data.Validated.{Invalid, Valid}
import cats.syntax.flatMap._
import cats.syntax.foldable._
import cats.syntax.functor._
import com.nulabinc.backlog.migration.common.codec.{UserMappingDecoder, UserMappingEncoder}
import com.nulabinc.backlog.migration.common.conf.BacklogApiConfiguration
import com.nulabinc.backlog.migration.common.domain.BacklogUser
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ object syntax {
EitherT(result.map(_ => Right(())))
}

implicit class EitherOps[F[_]: Monad, E, A](result: Either[E, A]) {
def lift: F[Either[E, A]] =
implicit class EitherOps[E, A](result: Either[E, A]) {
def lift[F[_]: Monad]: F[Either[E, A]] =
Applicative[F].pure(result)

def orFail: A =
Expand Down

0 comments on commit 5ef6a35

Please sign in to comment.