Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@zhxiaogg
Copy link
Contributor

@zhxiaogg zhxiaogg commented Mar 31, 2021

in an empty project with mleap-databricks-runtime dependency, the following code will fail:

val bytes = Array.emptyByteArray
val shape: DataShape = ml.bundle.DataShape.parseFrom(bytes)

with error message:

Symbol 'type scalapb.GeneratedMessageCompanion' is missing from the classpath.
This symbol is required by 'object ml.bundle.DataShape'.
Make sure that type GeneratedMessageCompanion is in your classpath and check for conflicting dependencies with `-Ylog-classpath`.
A full rebuild may help if 'DataShape.class' was compiled against an incompatible version of scalapb.
    val shape: DataShape = ml.bundle.DataShape.parseFrom(bytes)

value parseFrom is not a member of object ml.bundle.DataShape
    val shape: DataShape = ml.bundle.DataShape.parseFrom(bytes)

After some digging, I found this is due to shading of scalapb (which is a scala lib) was not supported by the previous sbt-assembly plugin. It has been fixed in an recently version of the plugin, see sbt/sbt-assembly#393.

@zhxiaogg zhxiaogg changed the title bump sbt assembly to fix scala lib shading not work issue bump sbt assembly to fix fat jar not work issue Mar 31, 2021
@zhxiaogg zhxiaogg changed the title bump sbt assembly to fix fat jar not work issue bump sbt-assembly to fix fat jar not working issue Mar 31, 2021
@zhxiaogg
Copy link
Contributor Author

zhxiaogg commented Apr 1, 2021

@ancasarb do u mind help reviewing this pr? will appreciate for it.

@zhxiaogg
Copy link
Contributor Author

zhxiaogg commented Apr 7, 2021

@ancasarb the test failure is not related to changes in this pr, I've submitted another pr to fix it, see #746

Copy link
Member

@ancasarb ancasarb left a comment

Choose a reason for hiding this comment

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

looks good, thanks for the fix!

@ancasarb ancasarb merged commit cccf354 into combust:master Apr 8, 2021
@zhxiaogg zhxiaogg deleted the bump-sbt-assembly branch April 8, 2021 10:08
@zhxiaogg
Copy link
Contributor Author

zhxiaogg commented Apr 8, 2021

Thanks @ancasarb , is it possible to get a patch release for now, like 0.16.x? or maybe 0.17.0.

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.

2 participants