Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Java Java Data Structures Organizing Data Serialization

Glen Hayes
Glen Hayes
5,798 Points

not serializable?

OMG information overload!

So, when trying to access the UID serial for serialver com.teamTreehouse.Treet I get the error:

Class com.teamTreehouse.Treet is not serializable

The Serializable method has been imported as per the video. I know the common practice is to post my code but at the moment I am not fussed with becoming a pro with serialization as my main goal is android app developement on a basic level(for now). I was just curious as to whether or not this was a simple coding error in general or something more complicated?

Christopher Augg
Christopher Augg
21,223 Points

It could be something simple. Did you also put implements Serializable within your class definition? Posting your code could definitely help us find your issue.

Regards,

Chris

Glen Hayes
Glen Hayes
5,798 Points

Thanks Christopher, I did add the implements Serializable in the class def. No real drama. Cheers

1 Answer

Mark Rae
Mark Rae
4,503 Points

Have you consistently used com.teamTreehouse as the package name? The standard for package names is to have them be all lowercase. The serialver tool might not be finding your class due to inconsistent package naming. Even if you are consistent in using camelCase, maybe serialver automatically makes the package name lowercase because it assumes you were following the convention and just mistyped something. In any case, I'd make sure your package name is lowercase and see if that solves the issue.