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

Protoquill transitive internal dependency breaks sbt-assembly #480

Open
Nexus6 opened this issue Jul 31, 2024 · 0 comments
Open

Protoquill transitive internal dependency breaks sbt-assembly #480

Nexus6 opened this issue Jul 31, 2024 · 0 comments

Comments

@Nexus6
Copy link

Nexus6 commented Jul 31, 2024

Scala Version: 3.4.2
SBT Version: 1.10.1
Protoquill Version: 4.8.5
Module: quill-sql
Database: postgresql

Expected behavior

Expect to be able to use sbt-assembly to package a stand-alone executable jar file containing protoquill 4.8.5.

Actual behavior

sbt-assembly errors-out because protoquill 4.8.5 has a transitive dependency on quill-engine 4.8.4 and the two jars contain classes that are different, but have the same fully-qualified names. Two examples among many from the console output when I run "sbt assembly":

[error] Deduplicate found different file contents in the following:
[error] Jar name = quill-engine_3-4.8.4.jar, jar org = io.getquill, entry target = io/getquill/context/ProtoStreamContext.class
[error] Jar name = quill-sql_3-4.8.5.jar, jar org = io.getquill, entry target = io/getquill/context/ProtoStreamContext.class
[error] Deduplicate found different file contents in the following:
[error] Jar name = quill-engine_3-4.8.4.jar, jar org = io.getquill, entry target = io/getquill/context/ExecutionInfo.class
[error] Jar name = quill-sql_3-4.8.5.jar, jar org = io.getquill, entry target = io/getquill/context/ExecutionInfo.class

Apart from the "assembly" step, the project builds and runs ("sbt run") just fine. Running a trivial query that uses protoquill 4.8.5 from the project also works w/no problems. There seem to be no compile-time or runtime issues.

Steps to reproduce the behavior

Include protoquill in your build.sbt as:
"io.getquill" %% "quill-jdbc" % "4.8.5"
Add the sbt-assembly plugin to your plugins.sbt:

addSbtPlugin ("com.eed3si9n" % "sbt-assembly" % "2.2.0")

then run "sbt assembly"

Workaround

N/A
@getquill/maintainers

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

1 participant