https://kotlinlang.org logo
s

SBNTT

11/16/2020, 12:03 AM
I tried to publish a mpp library using the 1.4.20-RC kotlin version No metadata module was published, so consumer project doesn't have autocomplete in common module How do i bring back the metadata module ?
l

louiscad

11/16/2020, 9:24 AM
Can you try simply reverting to 1.4.10 and check it works?
(changing nothing else as much as possible)
s

SBNTT

11/16/2020, 10:32 AM
Yes, using the 1.4.10, the metadata module is there but i'm facing another problem with it. (that's why i tried 1.4.20 versions) the thing is that the metadata module published with 1.4.10 version is platform dependant. I mean, if I published it from a linux host, then consumer project will be only able to build for linux targets see here: https://github.com/SBNTT/mpp-game-math/packages/503919 in the .module file:
"url": "../../mpp-game-math-linux_x64/0.1/mpp-game-math-linux_x64-0.1.module"
If i do not publish the metadata module, consumer projects can build for any target, but autocompletion in common module is not present
l

louiscad

11/16/2020, 10:33 AM
Oh, if you have a reproducing project, you can report on kotl.in/issue with the details, I think it can be helpful.
The observations on 1.4.10 will also be helpful in the report I think.
s

SBNTT

11/16/2020, 10:35 AM
i'm afraid i'm doing something wrong btw
l

louiscad

11/16/2020, 11:16 AM
Are you touching the modules names, group name, metadata configuration, or using a Gradle version older than 6.4?
Also, you are using the maven-publish plugin, and testing with mavenLocal?
everything works using a local repo, as i'm using macos to publish, and build macos runnable on the CI, metadata publication are done using a linux host, then i can't build for macos target as i explained before
and, gradle 6.6
l

louiscad

11/16/2020, 11:38 AM
Ah, this is expectable. Linux cannot build for incompatible targets. You need to run that on a mac. Many CIs offer that.
s

SBNTT

11/16/2020, 11:40 AM
no no no i mean, on the CI, metadata publication is done with a linux host then, on another project which depends on this library, only linux target can be built
l

louiscad

11/16/2020, 12:02 PM
Can you publishToMavenLocal instead, and use mavenLocal in the other project depending on the library?
s

SBNTT

11/16/2020, 12:10 PM
it suddenly begins to work without apparent reasons wtf Yes, when i was using local repository it worked .... surely it was a cache issue when i made tests with remote repositories
sorry, i I should have thought to clear gradle cache to force re download library before each test -_-
4 Views