Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump the scala version to 2.13.14 with rules_scala_toolchain_deps_repositories for multi-version #1596

Open
nlou9 opened this issue Aug 8, 2024 · 4 comments

Comments

@nlou9
Copy link

nlou9 commented Aug 8, 2024

The new release 6.6.0 support cross-compilation. I want to bump the scala version to 2.13.14 by overriding the artifacts. It turns out that it will override for both 2.12.18 and 2.13.14 with the artifacts which are supposed to be just for 2.13.14.
I think it is due to the hardcoded artifacts id

def _artifact_ids(scala_version):
which doesn't have version suffix.

Is there a way to achieve it to use scala 2.13.14?

scala_config(
    scala_version = "2.13.14", # Default Scala version
    scala_versions = [
        "2.12.18",
        "2.13.14",
    ],
)
scala_version = "2.13.14"
rules_scala_toolchain_deps_repositories(
    fetch_sources = True,
    overriden_artifacts = {
    "io_bazel_rules_scala_scala_library": {
        "artifact": "org.scala-lang:scala-library:%s" % scala_version,
        "sha256": "43e0ca1583df1966eaf02f0fbddcfb3784b995dd06bfc907209347758ce4b7e3",
    },
    "io_bazel_rules_scala_scala_compiler": {
        "artifact": "org.scala-lang:scala-compiler:%s" % scala_version,
        "sha256": "17b7e1dd95900420816a3bc2788c8c7358c2a3c42899765a5c463a46bfa569a6",
    },
    "io_bazel_rules_scala_scala_reflect": {
        "artifact": "org.scala-lang:scala-reflect:%s" % scala_version,
        "sha256": "8846baaa8cf43b1b19725ab737abff145ca58d14a4d02e75d71ca8f7ca5f2926",
    }
    }
)
@lukaszwawrzyk
Copy link

Handling artifact override seems to be a missed feature during multiversion implementation. Until fixed you need to stay with versions that are hardcoded in rules_scala.

The good news is that we will soon bump the scala versions. Additionally we hope to implement a solution that will make the bumps delivered faster.
The specific issue under this ticket should be fixed as well.

@nlou9
Copy link
Author

nlou9 commented Aug 12, 2024

good to know version bump to 2.13.14 is on the way. Do you have the ETA?

@lukaszwawrzyk
Copy link

#1597 PR is here, so it is the matter if getting it through CI, review and a release.

@simuons
Copy link
Collaborator

simuons commented Aug 26, 2024

@nlou9 sorry for delay. Version bump PR was merged. Thanks @lukaszwawrzyk

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

No branches or pull requests

3 participants