question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Updating to 2.7 breaks dependency resolution

See original GitHub issue

It looks like the update to 2.7 (with the new dependency resolution mechanism) is not working. The example script here worked just fine in 2.5, but in 2.7 I get some java.lang.NoClassDefFoundError errors.

Here’s the full output:

[kscript] Resolving dependencies...
[kscript]     Resolving io.github.javaeden.orchid:OrchidAll:0.16.1...Done
[kscript]     Resolving com.github.holgerbrandl:kscript-annotations:1.2...Done
[kscript] Dependencies resolved
Using the following modules:
--------------------
 * com.eden.orchid.StandardModule

Exception in thread "main" java.lang.reflect.InvocationTargetException
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
    at Main_Start$Companion.main(Main_Start.kt:6)
    at Main_Start.main(Main_Start.kt)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.jetbrains.kotlin.runner.AbstractRunner.run(runners.kt:61)
    at org.jetbrains.kotlin.runner.Main.run(Main.kt:109)
    at org.jetbrains.kotlin.runner.Main.main(Main.kt:119)
Caused by: java.lang.NoClassDefFoundError: com/vladsch/flexmark/ext/aside/AsideExtension
    at com.eden.orchid.impl.compilers.markdown.FlexmarkModule.configure(FlexmarkModule.kt:19)
    at com.google.inject.AbstractModule.configure(AbstractModule.java:61)
    at com.google.inject.spi.Elements$RecordingBinder.install(Elements.java:344)
    at com.google.inject.AbstractModule.install(AbstractModule.java:103)
    at com.eden.orchid.api.registration.ClasspathModuleInstaller.lambda$configure$0(ClasspathModuleInstaller.java:28)
    at java.util.ArrayList.forEach(ArrayList.java:1257)
    at com.eden.orchid.api.registration.ClasspathModuleInstaller.configure(ClasspathModuleInstaller.java:23)
    at com.google.inject.AbstractModule.configure(AbstractModule.java:61)
    at com.google.inject.spi.Elements$RecordingBinder.install(Elements.java:344)
    at com.google.inject.AbstractModule.install(AbstractModule.java:103)
    at com.eden.orchid.StandardModule.configure(StandardModule.kt:34)
    at com.google.inject.AbstractModule.configure(AbstractModule.java:61)
    at com.google.inject.spi.Elements$RecordingBinder.install(Elements.java:344)
    at com.google.inject.spi.Elements.getElements(Elements.java:103)
    at com.google.inject.internal.InjectorShell$Builder.build(InjectorShell.java:137)
    at com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:103)
    at com.google.inject.Guice.createInjector(Guice.java:87)
    at com.google.inject.Guice.createInjector(Guice.java:69)
    at com.eden.orchid.Orchid.start(Orchid.java:83)
    at Start.<init>(start.kts:45)
    ... 13 more
Caused by: java.lang.ClassNotFoundException: com.vladsch.flexmark.ext.aside.AsideExtension
    at java.net.URLClassLoader.findClass(URLClassLoader.java:382)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
    ... 33 more

This issue was initially discussed on the Orchid Gitter chat.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:2
  • Comments:24 (7 by maintainers)

github_iconTop GitHub Comments

2reactions
andreas-mauschcommented, Mar 28, 2019

Very likely 😦 …I can check it on Monday evening

1reaction
andreas-mauschcommented, Apr 4, 2019

@holgerbrandl I’ve tested 2.6.0 vs. a self-build 2.7.1.

After running 2.7.1 I can confirm I see the same error.

When executing the same script with 2.6.0, the error remains. But once I clean my ~/.kscript directory, the script runs without errors.

So yea, as assumed it’s on me. 😦 Sorry guys.

I try to fix it on Saturday.

Thanks @cjbrooks12 for the detailed info.

Read more comments on GitHub >

github_iconTop Results From Across the Web

[SOLVED] pacman doesn't update packages cuz of some ...
I have just performed all the steps you wrote down here and the pacman was able to upgrade the system. Thanks!
Read more >
Book's Upgrade: Migrating from Spring Boot 2.6 to 2.7
This upgrade breaks the book's code sources again, ... now 2.7.1 , to set the new Spring Boot version and get all the...
Read more >
yarn upgrade breaks dependencies #3202 - GitHub
Unfortunately due to the way module resolution works, node.js will find v2.6.0 before moving up the dep tree to find 2.7.1. I can...
Read more >
Can't update Spring boot to version 2.7.0, maven can't find it
If your local artifact repository got corrupted somehow, you can see broken dependency resolution. Adding -U as David suggested, or removing the ...
Read more >
yum --skip-broken never ending dependency resolution
I tried to install latest rawhide yum (yum-3.4.3-5.fc17.noarch.rpm) to my RHEL6 laptop, but it requires Python 2.7, which seems to be a bit ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found