Git Product home page Git Product logo

Comments (8)

nickbreen avatar nickbreen commented on June 26, 2024

In addition to runtime there is a case for provided dependencies too.

E.g. org.clojure:spec.alpha and org.clojure:clojure

Though it seems in this case it might just be a specific subset of versions that have the cycle.

from rules_jvm_external.

tmccombs avatar tmccombs commented on June 26, 2024

Is there any workaround for this?

from rules_jvm_external.

vorburger avatar vorburger commented on June 26, 2024

Is there any workaround for this?

Sometimes you can workaround using exclusions, like in grpc/grpc-java#10576.

from rules_jvm_external.

nickbreen avatar nickbreen commented on June 26, 2024

To avoid having to wade through that rather long issue the relevant bit is:


maven_install(
    artifacts = [
        "io.grpc:grpc-okhttp:1.58.0",
        maven.artifact(
            artifact = "grpc-core",
            exclusions = [
                "io.grpc:grpc-util",
            ],
            group = "io.grpc",
            version = "1.58.0",
        ),
    ],
    repositories = [
        "https://repo.maven.apache.org/maven2/",
    ],
)

from rules_jvm_external.

nickbreen avatar nickbreen commented on June 26, 2024

It looks like support for deps/runtime_deps/provided_deps is non-trivial.

  1. lock file JSON will need to differentiate the dep's scope (likely requiring a v3 lock file format) and have compile_dependencies , runtime_dependencies, and provided_dependencies keys or similar. Note that V2's dependencies is the union of the three new keys' values.
  2. pinning will need to generate the new lock file with the new keys
  3. consuming the lock file and ultimately generating the java_library rules needs to use new lock file and new keys.

from rules_jvm_external.

nickbreen avatar nickbreen commented on June 26, 2024

Looks like there's also a dependency on coursier's behaviour: coursier/coursier#1231

Rather, the json report from coursier is used: it does not differentiate dependencies' scopes.

from rules_jvm_external.

manjutapali avatar manjutapali commented on June 26, 2024

I am facing similar issue while trying to update the version of google-cloud-storage package.

Screenshot 2023-12-20 at 1 12 22 PM

I have tried the following suggestion as well, still it is failing.

        maven.artifact(
            artifact = "google-cloud-storage",
            exclusions = [
                "io.grpc:grpc-context",
            ],
            group = "com.google.cloud",
            version = "2.30.1",
        ),

from rules_jvm_external.

agluszak avatar agluszak commented on June 26, 2024

If you're using 5.3, that's because this commit is not included. I've filed a request to release a new version: #1014

from rules_jvm_external.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.