kotlin-examples icon indicating copy to clipboard operation
kotlin-examples copied to clipboard

Dokka multiproject example using Gradle

Open kamildoleglo opened this issue 5 years ago • 2 comments

kamildoleglo avatar Mar 20 '19 14:03 kamildoleglo

This fails for me when run locally.

$ ./gradlew.bat :projectA:dokka :projectB:dokka --stacktrace
> Task :projectB:dokka FAILED

...

1) Error injecting constructor, java.lang.RuntimeException: Exception while loading package-list from ExternalDocumentationLinkImpl(url=file://C:/Code/kotlin-examples/gradle/dokka-multiproject-gradle-example/projectA/build/dokka/project-a/, packageListUrl=file://C:/Code/kotlin-examples/gradle/dokka-multiproject-gradle-example/projectA/build/dokka/project-a/package-list)

...

Caused by: java.net.UnknownHostException: C
        at org.jetbrains.dokka.PackageListProvider.loadPackageList(ExternalDocumentationLinkResolver.kt:137)
        at org.jetbrains.dokka.PackageListProvider.<init>(ExternalDocumentationLinkResolver.kt:57)
        ... 83 more

nateridderman-lilly avatar Jun 24 '20 21:06 nateridderman-lilly

The package-list from projectA has not been generated yet, that's probably why this error occurs. You should run ./gradlew dokka or ./gradlew :projectA:dokka && ./gradlew :projectB:dokka if you wanted to run separate tasks (although that's not the point of this example)

kamildoleglo avatar Jun 24 '20 21:06 kamildoleglo