Jump to content
Frequently Asked Questions
  • Are you not able to open the client? Try following our getting started guide
  • Still not working? Try downloading and running JarFix
  • Help! My bot doesn't do anything! Enable fresh start in client settings and restart the client
  • How to purchase with PayPal/OSRS/Crypto gold? You can purchase vouchers from other users
  • Maven build throwing at runtime 'NoSuchMethodError' while the class exists in the JAR


    Recommended Posts

    Long story short I'm trying to build a script with maven because I want to use dependencies. 

    Currently I only have one dependency and that's the Apache Commons Lang3. I know from the guide that you have to pack the dependencies in the script JAR which I have setup successfully since when I open the jar I can see the class files of the dependency in there.

    For some reason though, when in the script I execute a method from the dependency I get the 'NoSuchMethodError'

    Can anyone think of why that possibly happens? Let me know if you need any additional information.

    I am using Eclipse IDE



    2:53:34 PM: [ERROR] The script had a problem starting:
        java.lang.NoSuchMethodError: 'java.lang.String org.apache.commons.lang3.StringUtils.capitalize(java.lang.String)'
        at adeline.Adeline.onStart(Adeline.java:34)
        at org.dreambot.api.script.AbstractScript.run(AbstractScript.java)
        at java.base/java.lang.Thread.run(Thread.java:833)

    My POM:

    <project xmlns="http://maven.apache.org/POM/4.0.0"
    	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    	<name>Dreambot Adeline</name>
    		<!-- java properties -->
    		<!-- https://mvnrepository.com/artifact/org.apache.commons/commons-lang3 -->
    	<!-- build jar file with dependencies -->


    Thanks for your attention!

    Link to comment
    Share on other sites


    This topic is now archived and is closed to further replies.

    • Create New...

    Important Information

    We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.