Kotlin / kotlin-interactive-shell

Kotlin Language Interactive Shell

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

:dependsOn does not load transitive dependencies

NorbertSandor opened this issue · comments

It seems that only the direct dependency is loaded, its transitive dependencies are not.
This makes even slightly complex dependencies unusable without lots of manual work :(

Embedding Maven Artifact Resolver would probably help a lot in the implementation.

Hi @NorbertSandor!

Could you give us an example please? Adding Maven Artefact Resolver is definitely not an option: it's too heavyweight (we've been considering it for some time)

It was my own library that had lots of transitive dependencies, and none of them was resolved/loaded (eg. kotlinx-datetime, kotlinx-coroutines, ...).
I gave up trying and searched for another solution :(
Thanks for your response :)

Adding Maven Artefact Resolver is definitely not an option

Without transitive dependency resolution, :dependsOn is useable only for very basic libraries :(

it's too heavyweight

I haven't used it yet, it was just an idea to use the "official" tool.
(Full-blown dependency resolution is not a simple task - maybe that's why it seems overly complex...)

But they all are available in the repository? May I ask you to give me coordinates of the dependency please?

It was only in my local Maven repository. It seemed that the library itself has been found but its dependencies were not resolved (ClassNotFoundError or NoClassDefFoundError at runtime when I tried to invoke functions from the library - sorry, I don't remember which one).

Yeah, maybe it's an issue with it being local repo. I'm almost sure it works for remote ones.
Still an issue tho