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
  • Need help uploading script


    Buffman

    Recommended Posts

    Hi all, 

    I've obviously messed something up in the process of uploading my script. For context i used inttelliji to write everything and used smart git. The script runs with no errors locally but when putting forward my script application i was given this error after having my request processed. 

     

    [javac] Compiling 3 source files to /opt/git/sdn/buffman/KillandTan/tempdist [javac] /opt/git/sdn/buffman/KillandTan/src/Mainclass.java:1: error: package com.sun.xml.internal.bind.v2.model.core does not exist [javac] import com.sun.xml.internal.bind.v2.model.core.ID; [javac] ^ [javac] /opt/git/sdn/buffman/KillandTan/src/Mainclass.java:17: error: package com.google.gson does not exist [javac] import com.google.gson.Gson; [javac] ^ [javac] /opt/git/sdn/buffman/KillandTan/src/Mainclass.java:18: error: package com.google.gson does not exist [javac] import com.google.gson.JsonObject; [javac] ^ [javac] /opt/git/sdn/buffman/KillandTan/src/Mainclass.java:19: error: package com.google.gson does not exist [javac] import com.google.gson.JsonParser; [javac] ^ [javac] /opt/git/sdn/buffman/KillandTan/src/Pricechecker.java:1: error: package com.google.gson does not exist [javac] import com.google.gson.Gson; [javac] ^ [javac] /opt/git/sdn/buffman/KillandTan/src/Pricechecker.java:2: error: package com.google.gson does not exist [javac] import com.google.gson.JsonObject; [javac] ^ [javac] /opt/git/sdn/buffman/KillandTan/src/Pricechecker.java:3: error: package com.google.gson does not exist [javac] import com.google.gson.JsonParser; [javac] ^ [javac] /opt/git/sdn/buffman/KillandTan/src/Pricechecker.java:19: error: cannot find symbol [javac] JsonObject query = new JsonParser().parse(cache).getAsJsonObject().getAsJsonObject(Integer.toString(id)); [javac] ^ [javac] symbol: class JsonObject [javac] location: class Pricechecker [javac] /opt/git/sdn/buffman/KillandTan/src/Pricechecker.java:19: error: cannot find symbol [javac] JsonObject query = new JsonParser().parse(cache).getAsJsonObject().getAsJsonObject(Integer.toString(id)); [javac] ^ [javac] symbol: class JsonParser [javac] location: class Pricechecker [javac] /opt/git/sdn/buffman/KillandTan/src/Pricechecker.java:20: error: cannot find symbol [javac] Gson gson = new Gson(); [javac] ^ [javac] symbol: class Gson [javac] location: class Pricechecker [javac] /opt/git/sdn/buffman/KillandTan/src/Pricechecker.java:20: error: cannot find symbol [javac] Gson gson = new Gson(); [javac] ^ [javac] symbol: class Gson [javac] location: class Pricechecker [javac] 11 errors BUILD FAILED  

     

    these are the files i uploaded from my src

     

    src.PNG.a4adc02846b113103d773fd4068f96ac.PNG

     

    I am still very new to this all so am struggling to work out what i have done wrong, If i had to guess i would say it has to do with whats in my src , since the files got through. Ive been looking through examples and tutorials and it seems my file structure could be wrong. I do see that the error talks about not finding gson and other imports and things not being found but i cant seem to work it out. I also learnt it could have something to do with thoose particular imports not being part of the public interface.

    iv'e done some more research and i believe its a problem with the library i used and it not working with javac compiler still looking for the best solution to get it to work with javac

    At this stage it all just makes my head hurt 

     

    thanks in advance  

    Link to comment
    Share on other sites

    Not sure how your project structure look like, if you are using maven, make sure Gson is compiled with dependency.
    Right now Intellij can't find Gson Dependency on build.

    Link to comment
    Share on other sites

    Wth, i cant edit my posts?

    Try an older Version of Gson as well, i had issue with the newest build as it contained Java 9 items.

     

       <!-- https://mvnrepository.com/artifact/com.google.code.gson/gson -->
            <dependency>
                <groupId>com.google.code.gson</groupId>
                <artifactId>gson</artifactId>
                <version>2.7</version>
                <scope>compile</scope>
            </dependency>

     

    Link to comment
    Share on other sites

    I ended up not using those libraries and changed the way that i grabbed the price, think that solved the issue, thanks for the help XZybez ill also try that because i liked using my old method of grabbing the price. 

    Link to comment
    Share on other sites

    Archived

    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.