GithubHelp home page GithubHelp logo

Comments (5)

autonomousapps avatar autonomousapps commented on August 23, 2024

Thanks for the issue. This is the result of assuming that the antlr project correctly declares its dependencies. In general, dependencies required at compile time are also required at runtime.

PRs that result in a smaller binary that still works are welcome.

from gradle-dependencies-sorter.

SimonMarquis avatar SimonMarquis commented on August 23, 2024

It seems like simply removing the transitive dependency keeps the build in good shape.
Although it might fail to decode non-standard chars like emojis and other special unicode characters 🤷

The new dependency graph is

------------------------------------------------------------
Project ':app'
------------------------------------------------------------

runtimeClasspath - Runtime classpath of compilation 'main' (target  (jvm)).
+--- org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.8.10
|    +--- org.jetbrains.kotlin:kotlin-stdlib:1.8.10
|    |    +--- org.jetbrains.kotlin:kotlin-stdlib-common:1.8.10
|    |    \--- org.jetbrains:annotations:13.0
|    \--- org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.8.10
|         \--- org.jetbrains.kotlin:kotlin-stdlib:1.8.10 (*)
+--- org.jetbrains.kotlin:kotlin-bom:1.8.10
|    +--- org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.8.10 (c)
|    +--- org.jetbrains.kotlin:kotlin-stdlib:1.8.10 (c)
|    +--- org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.8.10 (c)
|    \--- org.jetbrains.kotlin:kotlin-stdlib-common:1.8.10 (c)
+--- project :sort
|    +--- project :grammar
|    |    +--- org.antlr:antlr4:4.10.1
|    |    |    +--- org.antlr:antlr4-runtime:4.10.1
|    |    |    +--- org.antlr:antlr-runtime:3.5.3
|    |    |    +--- org.antlr:ST4:4.3.3
|    |    |    |    \--- org.antlr:antlr-runtime:3.5.2 -> 3.5.3
|    |    |    +--- org.abego.treelayout:org.abego.treelayout.core:1.0.3
|    |    |    \--- org.glassfish:javax.json:1.0.4
|    |    +--- org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.8.10 (*)
|    |    +--- org.jetbrains.kotlin:kotlin-bom:1.8.10 (*)
|    |    \--- org.antlr:antlr4-runtime:4.10.1
|    +--- org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.8.10 (*)
|    \--- org.jetbrains.kotlin:kotlin-bom:1.8.10 (*)
+--- info.picocli:picocli:4.6.2
\--- org.slf4j:slf4j-simple:2.0.5
     \--- org.slf4j:slf4j-api:2.0.5
-\--- project :sort
-     \--- project :grammar
-          \--- org.antlr:antlr4:4.10.1
-               \--- com.ibm.icu:icu4j:69.1

Which leads to this change in file size

-    18M Jul 22 11:09 sort-gradle-dependencies-app/0.4-SNAPSHOT/sort-gradle-dependencies-app-0.4-SNAPSHOT-all.jar
+   5.6M Jul 22 11:10 sort-gradle-dependencies-app/0.5-SNAPSHOT/sort-gradle-dependencies-app-0.5-SNAPSHOT-all.jar

from gradle-dependencies-sorter.

autonomousapps avatar autonomousapps commented on August 23, 2024

I'm not really thrilled about just accepting potential runtime failures for otherwise valid text. Can we talk about the justification for this?

from gradle-dependencies-sorter.

SimonMarquis avatar SimonMarquis commented on August 23, 2024

icu4j was added in antlr to expose unicode categories as tokens (similar to regex categories).
For example EMOJI = '\p{Emoji}'.
And I don't think we should "support this" specifically. Even if we want to support some specific characters, we probably don't really need their "category name".
Maybe the culprit is antlr's Gradle plugin which incorrectly adds the "tools" dependencies to the wrong classpath 🤷

FWIW: In the PR, they also talked about the size of this dependency.

from gradle-dependencies-sorter.

autonomousapps avatar autonomousapps commented on August 23, 2024

Ok, thanks for finding that PR! I'll respond further on the PR.

from gradle-dependencies-sorter.

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.