Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The same issue as #563 even I run Fiji with Java11 #609

Open
thuzyp opened this issue Sep 27, 2024 · 2 comments
Open

The same issue as #563 even I run Fiji with Java11 #609

thuzyp opened this issue Sep 27, 2024 · 2 comments

Comments

@thuzyp
Copy link

thuzyp commented Sep 27, 2024

I installed sciview in my Fiji Java8 and got the same error report as #563. So I followed a series of suggestions under that issue (and the related zulipchat) like installing a no-jre edition of Fiji, setting JVM as Java11 and using a launcher. But still, I got the same error report when starting Fiji:

[ERROR] Cannot create plugin: sc.iview.io.SMLMPointCloudIO
[ERROR] Cannot create plugin: sc.iview.io.N5IO
[ERROR] Cannot create plugin: sc.iview.io.OBJMeshIO
[ERROR] Cannot create plugin: sc.iview.io.SMLMPointCloudIO
[ERROR] Cannot create plugin: sc.iview.io.N5IO
[ERROR] Cannot create plugin: sc.iview.io.OBJMeshIO
[ERROR] Cannot create plugin: sc.iview.io.SMLMPointCloudIO
[ERROR] Cannot create plugin: sc.iview.io.N5IO
[ERROR] Cannot create plugin: sc.iview.io.OBJMeshIO

When I tried to run sciview, I got another report:

[ERROR] Cannot create plugin: sc.iview.ActiveSciViewPreprocessor
[ERROR] Cannot create plugin: sc.iview.ui.SwingGroupingInputHarvester
[ERROR] Cannot create module: sc.iview.commands.LaunchViewer
org.scijava.module.ModuleException: org.scijava.InstantiableException: Class not found: sc.iview.commands.LaunchViewer
	at org.scijava.command.CommandInfo.createModule(CommandInfo.java:316)
	at org.scijava.module.DefaultModuleService.createModule(DefaultModuleService.java:167)
	at org.scijava.module.DefaultModuleService.run(DefaultModuleService.java:206)
	at org.scijava.module.DefaultModuleService.run(DefaultModuleService.java:197)
	at org.scijava.module.DefaultModuleService.run(DefaultModuleService.java:182)
	at net.imagej.legacy.LegacyService.runLegacyCompatibleCommand(LegacyService.java:303)
	at net.imagej.legacy.DefaultLegacyHooks.interceptRunPlugIn(DefaultLegacyHooks.java:166)
	at ij.IJ.runPlugIn(IJ.java)
	at ij.Executer.runCommand(Executer.java:152)
	at ij.Executer.run(Executer.java:70)
	at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: org.scijava.InstantiableException: Class not found: sc.iview.commands.LaunchViewer
	at org.scijava.plugin.PluginInfo.loadClass(PluginInfo.java:290)
	at org.scijava.command.CommandInfo.loadClass(CommandInfo.java:243)
	at org.scijava.command.CommandInfo.createModule(CommandInfo.java:310)
	... 10 more
Caused by: java.lang.IllegalArgumentException: Cannot load class: sc.iview.commands.LaunchViewer
	at org.scijava.util.Types.iae(Types.java:977)
	at org.scijava.util.Types.load(Types.java:234)
	at org.scijava.plugin.PluginInfo.loadClass(PluginInfo.java:284)
	... 12 more
Caused by: java.lang.UnsupportedClassVersionError: sc/iview/commands/LaunchViewer has been compiled by a more recent version of the Java Runtime (class file version 65.0), this version of the Java Runtime only recognizes class file versions up to 55.0
	at java.base/java.lang.ClassLoader.defineClass1(Native Method)
	at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1016)
	at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:174)
	at java.base/java.net.URLClassLoader.defineClass(URLClassLoader.java:555)
	at java.base/java.net.URLClassLoader$1.run(URLClassLoader.java:458)
	at java.base/java.net.URLClassLoader$1.run(URLClassLoader.java:452)
	at java.base/java.security.AccessController.doPrivileged(Native Method)
	at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:451)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:588)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
	at org.scijava.util.Types.load(Types.java:226)
	... 13 more

So I want to know any other solutions for this problem. Thanks!

@thuzyp
Copy link
Author

thuzyp commented Sep 27, 2024

OK, now I realize that maybe I should run Fiji with Java21 because the class file edition is 65.0? But setting JVM as Java21 made Fiji could not launch.

@ctrueden
Copy link
Member

@thuzyp Here's the process I'm using currently to run sciview:

  1. Download and install Fiji.
  2. Install SciJava Ops as described in its documentation. This will get you switched over to Java 21 with Jaunch without needing to do it manually.
  3. Install sciview by enabling the sciview update site.

Sorry it's not easier yet, but I'm working on it!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants