Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Java (http://www.chiefdelphi.com/forums/forumdisplay.php?f=184)
-   -   ClassNotFound exception (http://www.chiefdelphi.com/forums/showthread.php?t=142693)

mikets 28-01-2016 02:08

ClassNotFound exception
 
Having to switch between Android Studio for FTC and Eclipse for FRC is hard. I have totally forgotten every little tricks I learned about Eclipse and roboRIO from last year. We copied our RecycleRush code from last season and stripped out the game specific code leaving pretty much a running base to the FirstStronghold code base. It compiled fine but when deploy the code to a simple 4-wheel drive base, it threw a ClassNotFoundException saying it cannot find the Robot class which is the root object of the program. I suspect it has something to do with copying last year's code and missing a rename somewhere in the manifest. The only rename we did was searching for all RecycleRush and replacing with FirstStronghold which are mainly strings for debugging purposes. Does anybody know what we missed?
Code:

Unhandled exception instantiating robot org.usfirst.frc.team492.robot.Robot java.lang.ClassNotFoundException

TimTheGreat 28-01-2016 17:07

Re: ClassNotFound exception
 
Can you post code? Either a github repo or your main robot class

mikets 29-01-2016 05:02

Re: ClassNotFound exception
 
You can find our code here:
https://github.com/trc492/Frc2016Fir...old/src/frc492

legts 30-01-2016 16:35

Re: ClassNotFound exception
 
Is your robot class called TrcRobot? It should probably be called Robot, I think.

java4first 31-01-2016 10:02

Re: ClassNotFound exception
 
You just need to edit the package and class name in the build.properties if you don't use the out of the box names from WPILibs wizard. We have a normal class path based on our website and call the main class Team501Robot. Every season I forget to do that the first pull, and have the same problem.

mikets 02-02-2016 16:36

Re: ClassNotFound exception
 
Thank you. I think that's what I am looking for. BTW anybody knows where to get the WPILib source code these days? It used to be first forge but I believe that doesn't exist any more. I also vaguely remember if I install the FRC update, the source code is zipped somewhere in some folder. But I searched all over and haven't found it yet.

fsilberberg 02-02-2016 18:11

We distribute the code in ~/wpilib. You can also clone them directly from our repository. The ScreenSteps for that is here: https://wpilib.screenstepslive.com/s...ing-the-source.


All times are GMT -5. The time now is 09:12.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi