Page 1 of 1

java.lang.ClassNotFoundException: loci.formats.in.SlideBook6

PostPosted: Sun Oct 29, 2017 11:37 am
by darwinjob
Hi
I get this error no matter what file I'm trying to read

[main] DEBUG loci.formats.ClassList - Could not find loci.formats.in.SlideBook6Reader
java.lang.ClassNotFoundException: loci.formats.in.SlideBook6Reader
at java.net.URLClassLoader.findClass(URLClassLoader.java:381) ~[na:1.8.0_45]
at java.lang.ClassLoader.loadClass(ClassLoader.java:424) ~[na:1.8.0_45]
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331) ~[na:1.8.0_45]
at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[na:1.8.0_45]
at java.lang.Class.forName0(Native Method) ~[na:1.8.0_45]
at java.lang.Class.forName(Class.java:264) ~[na:1.8.0_45]
at loci.formats.ClassList.parseLine(ClassList.java:196) [bioformats_package_5_7_1.jar:5.7.1]
at loci.formats.ClassList.parseFile(ClassList.java:258) [bioformats_package_5_7_1.jar:5.7.1]
at loci.formats.ClassList.<init>(ClassList.java:138) [bioformats_package_5_7_1.jar:5.7.1]
at loci.formats.ClassList.<init>(ClassList.java:122) [bioformats_package_5_7_1.jar:5.7.1]
at loci.formats.ImageReader.getDefaultReaderClasses(ImageReader.java:79) [bioformats_package_5_7_1.jar:5.7.1]
at loci.formats.ImageReader.<init>(ImageReader.java:116) [bioformats_package_5_7_1.jar:5.7.1]

Version 5.7.1, W764
Bug?

Re: java.lang.ClassNotFoundException: loci.formats.in.SlideB

PostPosted: Mon Oct 30, 2017 11:04 am
by sbesson
Hi,

this is not a bug but rather a consequence of the externalization of the 3i Slidebook reader from the Bio-Formats codebase.

Following this externalization, the 3i Slidebook JAR is now maintained in its own JAR, optional and detected at runtime when creating a new ImageReader instance. If the JAR is not found on the classpath, an exception is logged at the DEBUG level as shown by your stack trace.

How do you configure your logging? To reduce the noise, it is possible to set either the root logger level or the level of the `loci.formats.ClassList` logger at the INFO level or higher.

Best
Sebastien

Re: java.lang.ClassNotFoundException: loci.formats.in.SlideB

PostPosted: Mon Oct 30, 2017 1:11 pm
by darwinjob
OK, thanks. So this java.lang.ClassNotFoundException will not affect general functionality as far as I don't (and I don't) touch this SlideBook6 file format?

Re: java.lang.ClassNotFoundException: loci.formats.in.SlideB

PostPosted: Mon Oct 30, 2017 2:09 pm
by sbesson
The only impact would be that if you were to open Slidebook files, Bio-Formats would select the SlidebookReader in the main codebase rather than the native 3i Slidebook6 reader.

For any other usage of the library, the general functionality should be unaffected.

Best,
Sebastien

Re: java.lang.ClassNotFoundException: loci.formats.in.SlideB

PostPosted: Mon Oct 30, 2017 11:25 pm
by darwinjob
sbesson wrote:How do you configure your logging?

I don't. This is a minimalistic main() method running in Eclipse with the sole bioformats_package.jar referenced in the build path. This is the default output.

Re: java.lang.ClassNotFoundException: loci.formats.in.SlideB

PostPosted: Tue Oct 31, 2017 10:45 am
by sbesson
Understood,

if you are using bioformats_package.jar and want to reduce the logging as mentioned above, you should be able to configure logback by putting a configuration file in the class path - see the logback.xml file shipped with the command-line tools as an example.

Best,
Sebastien