JWrapper app crashes on all versions of OSX on load - java

I have a cross-platform Java app that I am deploying to Linux/Windows/OSX. Linux and Windows have been working fine for several months. I just went to test OSX, and I am finding that the JWrapper standalone offline launcher always crashes when I go to run the app (the install loading screen works and the proper JWrapper folders are created, however). Below is the log output from OSX and from my app regarding the crash. Looks like something memory related. No idea why this might be happening. Have tried disabling many advanced features of my app on startup to see if the crash goes away, to no avail.
OSX complains about this error:
Exception Type: EXC_BAD_ACCESS (SIGABRT)
Exception Codes: KERN_INVALID_ADDRESS at 0x0000000000000018
Exception Note: EXC_CORPSE_NOTIFY
Pastebin for JWrapper log output: http://pastebin.com/tcjLzN6J
Pastebin for OSX log output: http://pastebin.com/KnzaqL8z
Note that the real app name has been replaced with "MyApp"
UPDATE: according to the following, this might just be due to the fact that I'm testing in vmware: http://bugs.java.com/bugdatabase/view_bug.do?bug_id=8096072

It turns out that JavaFX just "won't work" on VMware, no matter what. I tried my app on friend's Mac Book, and experienced no errors so I am fairly certain now that that was the problem.

Related

Not working java on Mac m2 MacBook Air (any jar sent error)

It used to work on the MacBook pro 14 on the m1 pro. But now it has stopped working on it too. This is an application for the operation of IP KVM Aten cs1708i. As soon as I click Connect, the program hangs and then gives an error. I did a full reset of the mac and the same thing. Please help - I've already tried everything I could.
java.lang.UnsatisfiedLinkError: Can't load library: /var/folders/qs/570kgrkd07qf5r_67blv4d040000gn/T/libiKVMLib_V1.0.dylib
I tried to install various java builds (Azul,oracle, liberi). Java is installed - but the application does not work. Mac Os Ventura OS.
First try to see if your system sees Java. Go to a terminal and type
java -version
If it errors out, you need to add JAVA_HOME to your class path. Your class path is where your system looks for commands. Try google for installing java on your mac first and see how far you can get. Come back if you need help.

Android Studio not giving error on install of App on Vm

I recently made my project, worked fine and the recently I've been getting the following error:
Installation failed due to: 'closed'
Any idea on how do I go about fixing this ?
If any extra info is needed I'll be glad to provide.
Read your error carefully, it says Installation failed due to: 'closed', closed what? the device on which you are running your application has been closed before the installation of your Application.
Now there are two possibilities:
If you are running it on Physical Mobile Phone then its might be a problem in your wire plugins
Or if running on Virtual Machine then Read this Run apps on the Android Emulator and reinstall your VM.
and Also read this Configure hardware acceleration for the Android Emulator

Eclipse is unable to find adb even when specified in Run Configurations

I'm trying to run Appium tests with Java through Eclipse, but it can't find ANDROID_HOME. I've set the Run Configurations to use the ANDROID_HOME path and I've tried running Eclipse through terminal with open /Applications/Eclipse.app, but I'm still getting the error.
Worst part is this was all running fine yesterday, suddenly today Eclipse can't find the SDK. Running ADB in the terminal works fine as well. I changed nothing in the code
EDIT: I tried running a python test of Appium through terminal and got the same error. Restarted my machine and everything's working fine now lol. Not sure what the root cause is. This question can be closed
EDIT 2: It happened again, after around 30 minutes, started getting the error that it can't find adb. Is there a way to fix this? Right now it seems all I can do is restart my machine everytime it happens
Received the same error when running a pyhton script through terminal, which means the error is not constrained to Eclipse. Restarted machine and everything's working fine now.

How do I resolve a ClassFormatException in Play Framework 1.2.4?

Trying to run a Play! 1.2.4 app on OSX Snow Leopard under Java 1.6.0_33 but keep hitting this error after the login screen :-
An unexpected error occured caused by exception ClassFormatError:
Invalid index 95 in LocalVariableTable in class file
net/sf/oval/guard/Guard
but the same code works absolutely fine under Windows 7 and Java 7 and on WinXP (sorry, Java version not known on that one).
Is this a file permissions error on my application's path, masqueraded as a Java error, or is there something else?
Fixed!
Removed Play Framework, downloaded a fresh copy and re-ran the app and it worked fine. Old copy was restored from a backup so something may have gone awry there, but it's all good now.

I am not able launch JNLP applications using "Java Web Start"?

Up until recently, I was able to launch/open JNLP files in Firefox using Java web start.
Don't know what happened all of a sudden JNLP files stopped launching, a splash screen appears saying Java Starting... and then nothing happens. Even the Java Console in the browser and javacpl.cpl applet doesn't open.
Tried all possibilities: removed all older version and installed the latest JRE (java version "1.6.0_17"), still it doesn't work.
Done some googling for this problem, people suggested to start javaws.exe with -viewer option but same behavior (a splash screen appears saying "Java Starting..." and then disappears)
The problem is that I don't know any place (logs etc.) to look for to see what is causing the problem.
I am using WinXP SP3, and some of the screenshots below shows further info about my system.
I can provide any other detail if required but please help me solve this problem.
Have a look at what happens if you run javaws.exe directly from the command line.
I know this is an older question but this past week I started to get a similar problem, so I leave here some notes regarding the solution that fits me.
This happened only in some Windows machines using even the last JRE to date (1.8.0_45).
The Java Web Start started to load but nothing happened and none of the previous solution attempts worked.
After some digging i've found this thread, which gives the same setup and a great explanation.
https://community.oracle.com/thread/3676876
So, in conclusion, it was a memory problem in x86 JRE and since our JNLP's max heap was defined as 1024MB, we changed to 780MB as suggested and it was fixed.
However, if you need more than 780MB, can always try launching in a x64 JRE version.
i had the same problem here. go to your Java Control Panel and Settings... Uncheck 'Keep temporary files on my computer'. Apply changes and try again your .jnlp
Note: Tested on different machines; Windows Server 2012, Windows Server 2008 and Windows 7 64bit.
Java Version: 1.7++ since my jnlp app is built on 1.7
Please let me know your feedback too. :D
Java web start should be enabled.
Check if javaws (Java web start is enabled for your system), Use below command in console to open java control panel.
javaws -viewer
If javacpl does not open and gives you Could not find the main class:, it could be that Java is confused because of changes in deployment.properties (can be found in C:\Users\<username>\AppData\LocalLow\Sun\Java\Deployment on Win7). Delete that file and everything's fine.
This bug seems to be 6 years old, cf. An app should be able to ignore properties that have become obsolete over time, shouldn't it?
Although this question is bit old, the issue was caused by corrupted ClearType registry setting and resolved by fixing it, as described in this ClearType, install4j and case of Java bug post.
ClearType, install4j and case of Java bug Java
Do you know what
ClearType (font-smoothing technology in Windows) has in common with
Java (programming language and one of the recommended frameworks)?
Nothing except that they were working together hard at making me
miserable for few months. I had some Java software that I couldn’t
install. I mean really couldn’t – not even figure out reason or
reproduce it on another PC.
Recently I was approved for Woopra beta (site analytics service) and
it uses desktop client written in Java… I couldn’t install. That got
me really mad. :)
Story All of the software in question was similar :
setup based on install4j; setup crashing with bunch of errors. I was
blaming install4j during early (hundred or so) attempts to solve
issue. Later I slowly understood that if it was that bugged for that
long time – solution would have been created and googled.
Tracing After shifting focus from install4j I decided to push Java
framework. I was trying stable versions earlier so decided to go for
non-stable 1.6 Update 10 Release Candidate.
This actually fixed error messages but not crashes. I had also noticed
that there was new error log created in directory with setup files.
Previously I had only seen logs in Windows temporary directory.
New error log was saying following :
Could not display the GUI. This application needs access to an X
Server. If you have access there is probably an X library missing.
******************************************************************* You can also run this application in console mode without access to an
X server by passing the argument -c Very weird to look for X-Server on
non-Linux PC, isn’t it? So I decided to try that “-c” argument. And
was actually able to install in console mode.
Happy ending? Nope. Now installed app was crashing. But it really got
me thinking. If console works but graphical interface doesn’t – there
must be problem with latter.
One more error log (in application folder) was now saying (among other
things) :
Caused by: java.lang.IllegalArgumentException: -60397977 incompatible
with Text-specific LCD contrast key Which successfully googled me
description of bug with Java unable to read non-standard ClearType
registry setting.
Solution I immediately launched ClearType Tuner from Control Panel and
found setting showing gibberish number. After correcting it to proper
one all problems with Java were instantly gone.
cleartypetuner_screenshot Lessons learned Don’t be fast to blame
software problems on single application. Even minor and totally
unrelated settings can launch deadly chain reactions. Links Jave
Runtime Environment http://www.java.com/en/download/index.jsp
ClearType Tuner
http://www.microsoft.com/windowsxp/downloads/powertoys/xppowertoys.mspx
Woopra http://www.woopra.com/
install4j
http://www.ej-technologies.com/products/install4j/overview.html
I was also facing the same problem. To fix this to the following steps.
open Javaws from cmd runnig javaws -viewer command. A new window will open
Select the jnlp file which you want and click the run button.
Close the javaws viewer window.
Same solution worked as suggested by hpereira
The issue was due to JRE version was 32 bit and not 64 Bit
Check with java -version to see if your Java is 64 bit
C:\>java -version
java version "1.8.0_192"
Java(TM) SE Runtime Environment (build 1.8.0_192-b12)
Java HotSpot(TM) **64-Bit Server** VM (build 25.192-b12, mixed mode)
Is this an application to which you have the code? Java 6u14 included a change to the way it handles jar security that for us caused very similar issues. If your jars are signed and work with Java 6u13 or below, you might consider either refactoring your code to work around this update or requiring Java 6u13 or below. Unfortunately I don't recall exactly what we did to resolve the issue - it was panic mode at the time.
Again, if you have the code you have tools to work with. You can put in System.out.println statements in your startup routines - anything console output is displayed in the command window when you run the JNLP from the command line. Otherwise you might consider using a nice logger like log4j to get a better idea of the point of failure.
You may also consider removing the application entirely and downloading it anew. Java Web Start has a Control Panel applet that allows you to see the URL your app is downloading from (could be the wrong one), uninstall the app, set security options, etc.
I had the exact same problem. Turned out that the max-heap-size was set to 1024 and missing the unit. The configuration needed to be max-heap-size=1024m.
So apparently invalid memory configuration in the jnlp file will cause this exact behavior.
In my case, the problem was caused by starting my app from a shortcut on the public desktop (windows 7). As a result, as far as I can tell, the temporary files location was set to c:\users\public\etc. This resulted in the unable to write to cache detail. When I reset to defaults in the temporary files control applet, all worked fine.
In my case, Netbeans automatically creates a .jnlp file that doesn't work and my problem was due to an accidental overwriting of the launch.jnlp file on the server (by the inadequate and incorrect version from Netbeans). This caused a mismatch between the local .jnlp file and the remote .jnlp file, resulting in Java Web Start just quitting after "Verifying application."
So no one else has to waste an hour finding a bug that should be communicated adequately (but isn't) by Java WS.
This can also be due to environment variable CATALINA_HOME in your system. In our organization there were several cases where JNLP applications just refused to start without logging anything and emptying CATALINA_HOME solved the issue.
I had the environment variable set in the command prompt and it didn't appear in GUI. I'm not sure if setx command or register removal commands did the trick. Restart seems to be necessary after removing the variable.
I believe this is a security problem. If I download the jnpl file and execute it after a clean java 8 installation via javaws myfile.jnpl everything is working fine (I get multiple windows where I have to confirm some security problems).
I wanted to share the root cause for my issue. I was using High DPI in Windows and this caused JNLP to not launch. I had to turn off High DPI for this to work. Hope this helps.
Try Java Web Launcher, rather than Java Web Start Launcher. It worked for me.
Right-click on the JNLP file that is not opening and select Open With.
In the ‘How you want to open this File’ window, scroll down and click on Look for another app on this PC option.
When the File Explorer window opens, navigate to the following location:
C:\Program Files (x86)\Java\jre1.8.0_261\bin
or the folder for 64bit version
Select javaws.exe and click the Open button. This will open the JNLP file as intended.
Make sure to check the Always use this app to open .jnlp files.
That's all.

Categories