doobie v0.10.0-M2 Release Notes

Release Date: 2020-12-06 // over 3 years ago
  • Scala 3

    This release adds support for Scala 3.0.0-M2. It will remain a milestone version until all library dependencies are non-milestones.

    Differences between Scala 2 and Scala 3 versions
    • ๐Ÿš€ The postgres-circe, quill, scalatest, and specs2 modules are not yet available for Scala 3, pending releases of upstream dependencies.
    • Shapeless is not used in the Scala 3 version. Instances are derived via Tuple and Product rather than HList and Generic.
    • ๐Ÿ‘€ Get and Put instances cannot be derived for unary AnyVals in Scala 3. See lampepfl/dotty#7023
    Global Changes

    Most end users should note:

    • ๐Ÿ“ฆ The enum package has been renamed enumerated. For Scala 2 users an enum object remains behind as a bridge.
    • ๐Ÿšš Deprecated JDBC and Postgres Driver methods have been removed from the Free APIs.

    Advanced users should note:

    • doobie no longer relies on TypeTag, it uses TypeName instead.
    • Line number macros have been internalized; there is no longer a dependency on lihaoyi/sourcecode.

    Contributors should note:

    • โœ… Tests have been migrated from specs2 to MUnit.

Previous changes from v0.8.8

  • This is a follow-up to 0.8.7 which caused some runtime failures due to a change in the way the java.time.Instant mapping was defined. Mappings for temporal types now require an explicit import.

    ๐Ÿ“ฆ | Defining Package | Import | | --- | --- | | java.sql | import doobie.implicits.javasql._ | | java.time (JSR-310) | import doobie.implicits.javasql._ |

    Prior to v0.8.7 there were instances for Instant and LocalDate that were derived via the java.sql types Timestamp and Date, respectively. These are now hidden, but if you want the old behavior you can import them.

    Legacy Instance Import
    Instant import doobie.implicits.legacy.instant._
    LocalDate import doobie.implicits.legacy.localdate._

    Thanks to Andras Zsamboki for sorting this out.

    โž• Additional contributions:

    • ๐Ÿ“š Quill logging now works with doobie. Logs go to a logger called "DoobieContext" which can be enabled as described in the Quill documentation.
    • There is a new trivial example in the example/ module demonstrating a no-op interpreter.