Skip to content

v0.7.0: Scala 3.9.0, the newest libraries and plugins, and no zarr module - #31

Merged
cchlanger merged 12 commits into
mainfrom
cl/scala_3_9
Nov 13, 2026
Merged

cchlanger merged 12 commits into
mainfrom
cl/scala_3_9

Conversation

@cchlanger

@cchlanger cchlanger commented Nov 9, 2026 •

Copy link
Copy Markdown
Member

gerlib moves to Scala 3.9.0, the long-term support line, and to sbt 1.13.1. Its libraries and sbt plugins move to their newest releases within their major versions. The zarr module goes, with jzarr and Unidata's repository, which only it needed. CI runs the scalafmt and scalafix checks, which it had skipped until now, and tests on Java 21 only. looptrace's move to Scala 3.9 (gerlichlab/looptrace#583) needs this release.

Merge with a merge commit, not a squash or a rebase. The tag v0.7.0 is already pushed, on the version commit fb2edc6, and looptrace's submodule points at that commit. A merge commit puts it on main. A squash or a rebase would leave both on a commit that isn't on main.

Closes #30.

Breaking

  • Scala 3.9. An older Scala 3 compiler can't read a library compiled with 3.9, so a project that depends on v0.7.0 needs Scala 3.9 too.
  • No zarr module, and no readRoiData or getOriginZYX in roi. A project that uses them can stay on v0.6.0. The one other user is reparafil, which pins v0.3.0 and Scala 3.5.2.

Why the zarr module goes (#30)

  • Unidata: jzarr 0.4.2 brings Unidata's netCDF library, edu.ucar:cdm-core, and jblosc. cdm-core isn't on Maven Central, so every build had to name Unidata's repository.
  • Every user got it: roi depended on zarr only for readRoiData, so every user of roi or io brought all three. looptrace's JAR carried about 1,800 of their entries, and its build named Unidata's repository too.
  • CI broke on it: on 7 November, Java on GitHub's macOS runner rejected that repository's certificate, and looptrace's CI failed while publishing gerlib.
  • Nothing needs it: nothing else in gerlib used the module, and no test covered it. jzarr reads only format-2 stores, while looptrace's stores are format 3.

#30 proposed moving readRoiData into zarr. That would have kept Unidata's repository in gerlib's own build. It would also have stayed in looptrace's CI and image, which publish every module.

Other changes

  • Scala 3.6.4 → 3.9.0.
    • Under -source:future, 3.9 refuses implicit val and wants explicit implicit arguments passed with using. Each test suite's PropertyCheckConfiguration is now a given of the suite, which the compiler prefers over the inherited one.
    • The stricter unused-symbol checks removed unused imports and parameters. Among them is the A: Order bound of max on coordinates, which now asks for less.
  • sbt 1.12.13 → 1.13.1.
  • Libraries: iron 3.4.1, upickle and ujson 4.4.3, pureconfig 0.17.11, mouse 1.4.0, scala-graph 2.0.3, fs2-data-csv 1.14.1, fs2-io 3.14.0 and os-lib 0.11.10. For the tests: scalatest 3.2.20 and scalacheck 1.20.0.
  • iron's RefinedSubtype: NonnegativeInt, NonnegativeReal, PositiveInt, PositiveReal and Distance now extend it instead of RefinedType. They stay subtypes of what they refine, as they were before iron 3.1.0, so a PositiveInt is still an Int.
  • Untraced reads: since 4.4.0, upickle traces read by default, and a traced error's message is only the JSON path. DistanceLike's codec reads untraced, so its error still describes the problem with the value. A new test pins this.
  • Plugins:
    • sbt-assembly 2.5.0;
    • sbt-github-actions 0.32.2, which moves the workflow to actions/setup-java v6;
    • sbt-scalafmt 2.6.2, sbt-buildinfo 0.13.2 and sbt-scalafix 0.14.9;
    • typelevel's scalafix rules 0.6.0;
    • scalafmt 3.11.5.
  • CI's scalafmt and scalafix checks run. Their condition was never true: it compared the runner's OS with the label ubuntu-latest, and tested runner.java-version, which doesn't exist. It now tests runner.os == 'Linux' and the matrix's Java entry.
  • CI tests on Java 21 only, on Linux and macOS, the Java looptrace builds and runs gerlib with. The Ubuntu job on Java 17 is gone.
  • CI installs the sbt launcher the build asks for, 1.13.1, rather than setup-sbt's default, the newest one, so a new sbt release can't change how CI starts the build.

These come after the tag, so the changelog lists them under "Unreleased".

Commits

  • d4d1c0f sbt 1.13.1.
  • 4b05638 Scala 3.9.0.
  • 7e7bbec the libraries.
  • dc00a2e the plugins and scalafix rules.
  • e9bf4f8 scalafmt 3.11.5, which aligns six case arrows anew.
  • b1884f4 the CI checks run.
  • e73ed45 no zarr module.
  • fb2edc6 version 0.7.0, tagged v0.7.0.
  • 00f4c7b CI tests on Java 21 only.
  • 98a7dae CI installs the sbt launcher the build asks for.
  • a03c006 the changelog says why the launcher is pinned.

Checked

These checks ran on Java 21 (Zulu 21.0.11):

  • The tests: 69 passed, 1 pending.
  • scalafmt, scalafix and the workflow check are clean.
  • From a fresh clone, with an empty dependency cache: sbt "assembly; publishLocal", the command looptrace's Dockerfile runs, publishes the 12 modules. Nothing is downloaded from Unidata.
  • looptrace on this release (cl/jvm_updates, for gerlichlab/looptrace#583):
    • its Scala suite passes, with 160 tests passing and 47 pending;
    • its JAR holds no jzarr, cdm-core or jblosc.

Before merging

  • CI green, including the first real run of the scalafmt and scalafix checks.

Scala 3.6.4 is no longer patched. Under -source:future, 3.9 no longer
accepts implicit vals, and wants implicit arguments passed with using;
its unused-symbol checks, errors under -Werror, found unused imports,
lambda and pattern parameters, and an unused Order bound on the max of
coordinates. Each test suite's PropertyCheckConfiguration becomes a
given of the suite, which is preferred over the inherited one: a suite
asking for 500 cases still runs 500. TestCoordinates joins the files
whose imports serve only assertCompiles. The workflow names the new
version.
… version

iron 3.4.1, upickle and ujson 4.4.3, pureconfig 0.17.11, mouse 1.4.0,
scala-graph 2.0.3, fs2-data-csv 1.14.1, fs2-io 3.14.0 and os-lib
0.11.10; for the tests, scalatest 3.2.20 and scalacheck 1.20.0 with
scalatestplus' scalacheck-1-20. jzarr stays at 0.4.2, with the reason
beside it.

Since iron 3.1.0 a RefinedType is no longer a subtype of the type it
refines, so the five refined types extend RefinedSubtype, which keeps
them as they were. Since upickle 4.4.0 a read is traced by default, and
an error's message is only the JSON path: the DistanceLike codec reads
its parts untraced, so that its message still names the value's own
error, as a new test checks.
…itory

The zarr module read format-2 Zarr stores with jzarr 0.4.2, which brings
Unidata's netCDF library (edu.ucar:cdm-core) and jblosc. cdm-core is not
on Maven Central, so every build had to name Unidata's repository, and
Java on GitHub's macOS runner now rejects that repository's certificate:
looptrace's CI failed fetching cdm-core while publishing this library.

roi depended on zarr only for readRoiData and its helper getOriginZYX,
so roi and io, and whatever depends on them, brought all three. Nothing
else here used them, no test covered them, and jzarr can't read format-3
stores. The module, the two functions, jzarr and the Unidata resolver
are gone. roi names imaging, which it used and had through zarr.

Closes #30.
looptrace builds and runs gerlib with Java 21. CI drops its Ubuntu job
on Java 17 and tests on Java 21 alone, on Linux and macOS.
setup-sbt installs the newest sbt launcher unless told otherwise, now
2.0.12, and on 9 November GitHub answered every download of its zip
with a 504, so every job failed in "Setup sbt". CI now installs the
version project/build.properties names, as the job setup passes it to
setup-sbt.
The entry said the pin avoided GitHub's failed downloads of sbt
2.0.12's zip. It doesn't: the same day, during an incident with
timeouts on GitHub's release downloads, 1.13.1's zip failed too. What
the pin does is install the launcher the build asks for, so a new sbt
release can't change how CI starts the build.

@valesori valesori left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok for me to merge!

The build preamble installed sbt with Homebrew on macOS, for runners
whose setup-java no longer brought sbt. setup-sbt now installs the
launcher on every runner, and the macOS log shows Homebrew's sbt
shadowed by it, so the step only added a second sbt and about 7 s.
@cchlanger
cchlanger marked this pull request as ready for review November 13, 2026 13:23
@cchlanger
cchlanger merged commit 0096a45 into main Nov 13, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

roi depends on zarr only for readRoiData, so jzarr and Unidata's netCDF library reach every user of roi and io

2 participants