Skip to content

Commit

Permalink
Upgrade dependencies to Guice 7 (#2781)
Browse files Browse the repository at this point in the history
* Upgrade to guice 6

* Upgrade to guice 7

Guice 7 dropped support for `javax.inject.*`
in favor of `jakarta.inject.*`:
https://github.com/google/guice/wiki/Guice700#jee-jakarta-transition

Since we do not want to pull in Java EE, we're
switching to the properietary `com.google` package.
  • Loading branch information
thpani authored Nov 23, 2023
1 parent eb73de4 commit c40dc46
Show file tree
Hide file tree
Showing 12 changed files with 12 additions and 14 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package at.forsyte.apalache.infra

import javax.inject.Singleton
import com.google.inject.Singleton

/**
* The default adapter does nothing.
Expand Down
2 changes: 1 addition & 1 deletion project/Dependencies.scala
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ object Dependencies {
"commons-beanutils" % "commons-beanutils" % "1.9.4" // Apparently an untracked dependency of commonsConfiguration2
val commonsConfiguration2 = "org.apache.commons" % "commons-configuration2" % "2.9.0"
val commonsIo = "commons-io" % "commons-io" % "2.15.0"
val guice = "com.google.inject" % "guice" % "5.1.0"
val guice = "com.google.inject" % "guice" % "7.0.0"
val kiama = "org.bitbucket.inkytonik.kiama" %% "kiama" % "2.5.1"
val logbackClassic = "ch.qos.logback" % "logback-classic" % logbackVersion
val logbackCore = "ch.qos.logback" % "logback-core" % logbackVersion
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,9 @@ import at.forsyte.apalache.tla.lir.{
}
import at.forsyte.apalache.tla.pp.{IrrecoverablePreprocessingError, NotInKeraError, OverridingError, TlaInputError}
import at.forsyte.apalache.tla.typecheck.TypingInputException
import com.google.inject.{Inject, Singleton}
import com.typesafe.scalalogging.LazyLogging

import javax.inject.{Inject, Singleton}

/**
* The adapter for all exceptions that can be produced when running the model checker.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package at.forsyte.apalache.tla.imp
import at.forsyte.apalache.infra.ExceptionAdapter
import com.typesafe.scalalogging.LazyLogging

import javax.inject.{Inject, Singleton}
import com.google.inject.{Inject, Singleton}

// TODO: This can be removed in theory, but our current architecture requires executable passes
// include a injectable instance of `ExceptionAdapater`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import at.forsyte.apalache.tla.lir.oper._
import at.forsyte.apalache.tla.lir.transformations.{TlaExTransformation, TransformationTracker}
import at.forsyte.apalache.tla.lir.values.{TlaInt, TlaStr}

import javax.inject.Singleton
import com.google.inject.Singleton
import at.forsyte.apalache.tla.typecomp.ScopedBuilder

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ import at.forsyte.apalache.tla.lir.transformations.{LanguageWatchdog, TlaExTrans
import at.forsyte.apalache.tla.lir.values.{TlaInt, TlaStr}
import TypedPredefs._

import javax.inject.Singleton
import scala.math.BigInt
import com.google.inject.Singleton

/**
* <p>An optimizer of KerA+ expressions.</p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import at.forsyte.apalache.tla.lir.oper._
import at.forsyte.apalache.tla.lir.transformations.standard.FlatLanguagePred
import at.forsyte.apalache.tla.lir.transformations.{LanguageWatchdog, TlaExTransformation, TransformationTracker}

import javax.inject.Singleton
import com.google.inject.Singleton

/**
* <p>A simplifier from TLA+ to KerA+. This transformation assumes that all operator definitions and internal
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import at.forsyte.apalache.tla.lir.transformations.{LanguageWatchdog, TlaExTrans
import at.forsyte.apalache.tla.lir.values.TlaBool
import at.forsyte.apalache.tla.lir._

import javax.inject.Singleton
import com.google.inject.Singleton

/**
* This transformation turns subexpressions of a TLA+ expression into negated normal form.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import at.forsyte.apalache.tla.lir._
import at.forsyte.apalache.tla.lir.transformations.{TlaExTransformation, TransformationTracker}
import at.forsyte.apalache.tla.types.Substitution

import javax.inject.Singleton
import com.google.inject.Singleton

/**
* <p>Apply a type substitution to the types of a subexpression.</p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package at.forsyte.apalache.tla.pp.temporal

import at.forsyte.apalache.tla.lir._

import javax.inject.Singleton
import com.google.inject.Singleton
import com.typesafe.scalalogging.LazyLogging
import at.forsyte.apalache.tla.typecomp._
import at.forsyte.apalache.tla.pp.temporal.DeclUtils._
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package at.forsyte.apalache.tla.pp.temporal

import at.forsyte.apalache.tla.lir._

import javax.inject.Singleton
import com.google.inject.Singleton
import com.typesafe.scalalogging.LazyLogging
import scalaz.Scalaz.{init => _}
import at.forsyte.apalache.tla.pp.UniqueNameGenerator
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import at.forsyte.apalache.tla.lir.transformations.{
TlaDeclTransformation, TlaExTransformation, TlaModuleTransformation, TransformationTracker,
}

import javax.inject.{Inject, Singleton}
import com.google.inject.{Inject, Singleton}
import scala.collection.immutable.HashMap

// Igor @ 07.11.2019: refactoring needed
Expand Down

0 comments on commit c40dc46

Please sign in to comment.