MarvinSketch 5.5 fails to launch in browser

User 870ab5b546

10-05-2011 13:49:37

Safari 5.0.5 on MacOS 10.3.8.  Java Preferences lists Java SE 6 64-bit, J2SE 5.0 32-bit, and J2SE 5.0 64-bit.  When I go to your Marvin page, the applet fails to launch, showing "Error.  Click for details."  When I ask for details, I see the following error message in the Java console:


basic: Exception: java.lang.UnsupportedClassVersionError: Bad version number in .class file

I have repeatedly emptied both the browser and the Java caches, to no avail.  Please advise.

ChemAxon 7c2d26e5cf

12-05-2011 11:42:35

Are you sure that your Safari uses Java 1.6 plugin?


Marvin 5.5 requires Java 1.6. Resources are compiled with Java 1.6. So, old Java versions can not launch Marvin.

User 870ab5b546

12-05-2011 13:16:54

Here's a screenshot of my Java Preferences window.

ChemAxon 7c2d26e5cf

17-05-2011 13:05:01

It is hard to decide which Java is used by your browser since there are several Java versions are available on your machine.


Please visit the following page:


http://old.chemaxon.com/test/JavaAppletVersion.html


It includes an applet that determines your Java Plugin.


Please send the result that it generates.

User 870ab5b546

18-05-2011 02:54:07

I got the same error as when I tried to launch MarvinSketch.  The Java applet would not launch, and when I asked for details, the last line in the Java console read:


basic: Exception: java.lang.UnsupportedClassVersionError: Bad version number in .class file


However, if I go to the Sun Java test page here, I see the attached screen shot, showing clearly that Java is working.t


If I uncheck the two J2SE 5.0 boxes in my Java Preferences window, so that only the Java SE 6 box is checked, MarvinSketch 5.5 still fails to launch.

ChemAxon 7c2d26e5cf

18-05-2011 11:32:42

Both the java.lang.UnsupportedClassVersionError and the Sun Java Test page proves that your browser still uses Java Plugin 1.5.


I have OS X 10.6 where Java 1.6 is the default.


After a small research in this subject, I have found the following document that descibes how to upgrade the default Java under OS X 10.5:


http://memerocket.com/2009/08/06/upgrade-os-x-10-5-8-to-jdk-1-6/


I have also found an Apple forum where customers reported the same Java Plugin update issue.


https://discussions.apple.com/thread/2040989?threadID=2040989


Although it is not a fresh topic, they says that Safari requires 32-bit Java. So the lack of 32bit Java 1.6 may be the cause of the unsuccessful Java Plugin upgrade. I can imagine that the installation of a 32bit Java 1.6 can solves the problem.


It seems that you are not the only one who meets with the Java upgrade problem under OS X 10.5.


It can be useful to consult with other OS X 10.5 users on the net.





User 870ab5b546

18-05-2011 13:46:53

Interesting... And completely unexpected, as Java Preferences claims that I have and use Java 1.6.


I doubt I am the only Mac user who is experiencing this problem.  Maybe you can show a more helpful error message if the user does not have Java 1.6?


I tried the suggestions in the post.


Grossman-CP-339-iMac-2:~ Bob$ cd /System/Library/Frameworks/JavaVM.framework/Versions
Grossman-CP-339-iMac-2:Versions Bob$ ls -l
total 64
lrwxr-xr-x 1 root wheel 5 Mar 9 16:31 1.3 -> 1.3.1
drwxr-xr-x 3 root wheel 102 Dec 2 2007 1.3.1
lrwxr-xr-x 1 root wheel 5 Sep 10 2009 1.4 -> 1.4.2
lrwxr-xr-x 1 root wheel 3 Aug 30 2008 1.4.1 -> 1.4
drwxr-xr-x 8 root wheel 272 Aug 30 2008 1.4.2
lrwxr-xr-x 1 root wheel 5 Mar 9 16:31 1.5 -> 1.5.0
drwxr-xr-x 8 root wheel 272 Aug 30 2008 1.5.0
lrwxr-xr-x 1 root wheel 5 Mar 9 16:31 1.6 -> 1.6.0
lrwxr-xr-x 1 root wheel 59 Mar 9 16:31 1.6.0 -> /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents
drwxr-xr-x 10 root wheel 340 Mar 9 16:31 A
lrwxr-xr-x 1 root wheel 1 Mar 9 16:31 Current -> A
lrwxr-xr-x 1 root wheel 3 May 18 09:58 CurrentJDK -> 1.5

Grossman-CP-339-iMac-2:Versions Bob$ sudo rm -fr CurrentJDK
Grossman-CP-339-iMac-2:Versions Bob$ sudo ln -s 1.6 CurrentJDK
Grossman-CP-339-iMac-2:Versions Bob$ ls -l
total 64
lrwxr-xr-x 1 root wheel 5 Mar 9 16:31 1.3 -> 1.3.1
drwxr-xr-x 3 root wheel 102 Dec 2 2007 1.3.1
lrwxr-xr-x 1 root wheel 5 Sep 10 2009 1.4 -> 1.4.2
lrwxr-xr-x 1 root wheel 3 Aug 30 2008 1.4.1 -> 1.4
drwxr-xr-x 8 root wheel 272 Aug 30 2008 1.4.2
lrwxr-xr-x 1 root wheel 5 Mar 9 16:31 1.5 -> 1.5.0
drwxr-xr-x 8 root wheel 272 Aug 30 2008 1.5.0
lrwxr-xr-x 1 root wheel 5 Mar 9 16:31 1.6 -> 1.6.0
lrwxr-xr-x 1 root wheel 59 Mar 9 16:31 1.6.0 -> /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents
drwxr-xr-x 10 root wheel 340 Mar 9 16:31 A
lrwxr-xr-x 1 root wheel 1 Mar 9 16:31 Current -> A
lrwxr-xr-x 1 root wheel 3 May 18 09:58 CurrentJDK -> 1.6

Grossman-CP-339-iMac-2:Versions Bob$ java -version
java version "1.6.0_24"
Java(TM) SE Runtime Environment (build 1.6.0_24-b07-334-9M3326)
Java HotSpot(TM) 64-Bit Server VM (build 19.1-b02-334, mixed mode)

However, even after restarting my computer, I still can't load MarvinSketch.  The Sun Java site still says that I am running J2SE 5 (unchanged from previously), both in Safari 5.0.5 and Firefox 3.6.17.  If I uncheck the J2SE 5 boxes in Java preferences, there is no change in Safari's behavior, and Firefox won't even load the Sun Java test applet.

ChemAxon 7c2d26e5cf

18-05-2011 22:39:48

 


Maybe you can show a more helpful error message if the user does not have Java 1.6?

Theoretically, users know that new Marvin requires Java 1.6. :-)
This fact is registered in the documentation:


http://www.chemaxon.com/marvin/help/applications/install.html#requirements


and in the changes list too:


http://www.chemaxon.com/marvin/help/developer/changes.html style="line-height: 15px;"> (Marvin 5.5 -> New features and improvements -> Compatibility)


Anyhow, it is a good idea to drop some (more informative) warning if applet is attempted to load by a wrong Java version.


It seems that  java.lang.UnsupportedClassVersionError is not too informative.


However, even after restarting my computer, I still can't load MarvinSketch.  The Sun Java site still says that I am running J2SE 5 (unchanged from previously), both in Safari 5.0.5 and Firefox 3.6.17.  If I uncheck the J2SE 5 boxes in Java preferences, there is no change in Safari's behavior, and Firefox won't even load the Sun Java test applet.

This fact confirms my earlier assumption. Safari requires 32bit Java plugin. You have only 64bit Java 1.6 package that Safari does not accept. A 32bit Java 1.6 package should be installed.

User 870ab5b546

19-05-2011 00:02:04










Tamas wrote:

 


Maybe you can show a more helpful error message if the user does not have Java 1.6?

Theoretically, users know that new Marvin requires Java 1.6. :-)
This fact is registered in the documentation:


http://www.chemaxon.com/marvin/help/applications/install.html#requirements


and in the changes list too:


http://www.chemaxon.com/marvin/help/developer/changes.html style="line-height: 15px;"> (Marvin 5.5 -> New features and improvements -> Compatibility)



Yes, of course.  But my Java Preferences file is showing that I have and am using Java 1.6, and my browser is not telling me that it is choosing not to use it.  So you see how I could be confused.

User 870ab5b546

19-05-2011 01:06:10










Tamas wrote:

This fact confirms my earlier assumption. Safari requires 32bit Java plugin. You have only 64bit Java 1.6 package that Safari does not accept. A 32bit Java 1.6 package should be installed.



From what I can tell on the Web, there is neither a 32-bit Java 1.6 package nor a 64-bit browser for MacOS 10.5. (There is a SoyLatte 32-bit Java 1.6 package on the Web, but it doesn't enable browsers to run Java 1.6 applets.  I tried installing it according to the instructions, and it made Java Preferences unlauchable.)  


In other words, it appears that there is no way to run Java 1.6 within a MacOS 10.5 browser.


It therefore follows that Marvin 5.5 is not compatible with MacOS 10.5 or earlier.


I respectfully request that you rectify this problem.  Snow Leopard was released less than two years ago, so there are still a lot of Macs out there that do not run it.

User 870ab5b546

20-05-2011 01:06:30

OK, I found a 64-bit browser for MacOS 10.5: iCab 4.8!  (I had not looked at iCab for many, many years.)  It loads MarvinSketch 5.5.


Do you know if there is any reason to suspect incompatibilities between iCab and Marvin?

User 870ab5b546

20-05-2011 01:15:38

OK, I found a 64-bit browser for MacOS 10.5: iCab 4.8!  (I had not looked at iCab for many, many years.)  It loads MarvinSketch 5.5.


Do you know if there is any reason to suspect incompatibilities between iCab and Marvin?

ChemAxon 7c2d26e5cf

23-05-2011 10:20:36

We have not tested iCab with OS X yet. But it does not mean that it can not be compatible with Marvin. :)


We are going to test it. So you can use it free.

ChemAxon 5433b8e56b

23-05-2011 11:05:45

Hi Bob,


please set the java preferences to run java applets in its own process.


If the java vm start within the browser, and you use a 32-bit browser then it could not start the 64-bit wm process within the browser process.


I have tested it and if the applet runs in its own separate process, the Marvin applets are able to start in safari also.


I hope this solves the problem.


Regards,
Istvan

User 870ab5b546

23-05-2011 14:45:26

Progress, but no joy.


In Java Preferences, I set applets to run in their own process, and I told it to show the Java console.  I emptied the Java cache and the Safari cache and restarted my computer.  When I went to your MarvinSketch demo page, the Java console showed, and the last thing that appeared was,


User home directory = /Users/bobload: class chemaxon/marvin/applet/JMSketch not found.
java.lang.ClassNotFoundException: chemaxon.marvin.applet.JMSketch
at sun.plugin2.applet.Applet2ClassLoader.findClass(Applet2ClassLoader.java:195)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Plugin2ClassLoader.java:250)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Plugin2ClassLoader.java:180)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Plugin2ClassLoader.java:161)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Plugin2ClassLoader.java:687)
at sun.plugin2.applet.Plugin2Manager.createApplet(Plugin2Manager.java:3046)
at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Plugin2Manager.java:1498)
at java.lang.Thread.run(Thread.java:655)
Exception: java.lang.ClassNotFoundException: chemaxon.marvin.applet.JMSketch

A coffee cup appeared in the place where the MarvinSketch applet should have appeared.  Then the Java console closed itself, and the coffee cup was not replaced with the applet.  The browser did not hang; I could use it to do other things.


I went to Marvin 5.4, and exactly the same thing happened.  


I set Java 1.6 to SoyLatte 1.0.3.  Now I could load Marvin 5.4 into my browser.  When I went to Marvin 5.5, however, I again did not proceed beyond the coffee sup.  I saw this message in the Java console before it crashed:


basic: Plugin2ClassLoader.getPermissions CeilingPolicy allPerms
java.lang.InterruptedException
at java.lang.Object.wait(Native Method)
at java.lang.Object.wait(Object.java:474)
at com.sun.deploy.util.DeployAWTUtil.invokeAndWait(DeployAWTUtil.java:111)
at sun.plugin2.applet.Plugin2Manager.runOnEDT(Plugin2Manager.java:3542)
at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Plugin2Manager.java:1818)
at java.lang.Thread.run(Thread.java:655)
basic: Finished applet teardown

It appears that trying to run the applet in its own process causes more problems than it solves.


Addendum: Even though the first time I tried to load Marvin 5.4 with the applet running in its own process, the subsequent times that I tried it, it did work.  However, I still can't get Marvin 5.5 to load.

ChemAxon 7c2d26e5cf

26-05-2011 10:32:23

Thanks for sharing your experience.


We are also going to investigate these cases.