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

macOS exception error #468

Closed
red-ochre opened this issue Apr 11, 2023 · 2 comments
Closed

macOS exception error #468

red-ochre opened this issue Apr 11, 2023 · 2 comments

Comments

@red-ochre
Copy link

Running AudiobookConverter 6.1.2 on Ventura 13.3.1 on M2 MacBook Pro but I had similar exception errors on Intel MacBook Air.

Granted: Settings > Security & Privacy > Developer Tools > ticked Terminal.
In terminal, I enter:
cd /Applications/AudiobookConverter.app
./Contents/MacOS/AudiobookConverter
App starts — looks OK.
Drag & drop a single mp3 file to main app input area. No file is added and Terminal shows exception error:

Exception in thread "JavaFX Application Thread" java.lang.NoClassDefFoundError: Could not initialize class uk.yermak.audiobookconverter.Platform
	at uk.yermak.audiobookconverter.loaders.FFMediaLoader.loadMediaInfo(FFMediaLoader.java:39)
	at uk.yermak.audiobookconverter.fx.FilesController.processFiles(FilesController.java:197)
	at uk.yermak.audiobookconverter.fx.FilesController.lambda$addDragEvenHandlers$13(FilesController.java:160)
	at javafx.base/com.sun.javafx.event.CompositeEventHandler.dispatchBubblingEvent(CompositeEventHandler.java:86)

then many more lines with similar errors.

Different scenario:
Instead of drag & drop, goto File > Add and click Files
No Finder window opens and Terminal shows exception error:

Exception in thread "JavaFX Application Thread" java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
	at javafx.fxml/javafx.fxml.FXMLLoader$MethodHandler.invoke(FXMLLoader.java:1857)
	at javafx.fxml/javafx.fxml.FXMLLoader$ControllerMethodEventHandler.handle(FXMLLoader.java:1724)
	at javafx.base/com.sun.javafx.event.CompositeEventHandler.dispatchBubblingEvent(CompositeEventHandler.java:86)
	at javafx.base/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(EventHandlerManager.java:234)
	at javafx.base/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(EventHandlerManager.java:191)
	at javafx.base/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:58)
	at javafx.base/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at javafx.base/com.sun.javafx.event.EventUtil.fireEventImpl(EventUtil.java:74)
	at javafx.base/com.sun.javafx.event.EventUtil.fireEvent(EventUtil.java:49)
	at javafx.base/javafx.event.Event.fireEvent(Event.java:198)
	at javafx.controls/javafx.scene.control.MenuItem.fire(MenuItem.java:459)
	at javafx.controls/com.sun.javafx.scene.control.ContextMenuContent$MenuItemContainer.doSelect(ContextMenuContent.java:1385)
	at javafx.controls/com.sun.javafx.scene.control.ContextMenuContent$MenuItemContainer.lambda$createChildren$12(ContextMenuContent.java:1338)
	at javafx.base/com.sun.javafx.event.CompositeEventHandler$NormalEventHandlerRecord.handleBubblingEvent(CompositeEventHandler.java:247)
	at javafx.base/com.sun.javafx.event.CompositeEventHandler.dispatchBubblingEvent(CompositeEventHandler.java:80)
	at javafx.base/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(EventHandlerManager.java:234)
	at javafx.base/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(EventHandlerManager.java:191)
	at javafx.base/com.sun.javafx.event.CompositeEventDispatcher.dispatchBubblingEvent(CompositeEventDispatcher.java:59)
	at javafx.base/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:58)
	at javafx.base/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at javafx.base/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56)
	at javafx.base/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at javafx.base/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56)
	at javafx.base/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at javafx.base/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56)
	at javafx.base/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at javafx.base/com.sun.javafx.event.EventUtil.fireEventImpl(EventUtil.java:74)
	at javafx.base/com.sun.javafx.event.EventUtil.fireEvent(EventUtil.java:54)
	at javafx.base/javafx.event.Event.fireEvent(Event.java:198)
	at javafx.graphics/javafx.scene.Scene$MouseHandler.process(Scene.java:3897)
	at javafx.graphics/javafx.scene.Scene.processMouseEvent(Scene.java:1878)
	at javafx.graphics/javafx.scene.Scene$ScenePeerListener.mouseEvent(Scene.java:2623)
	at javafx.graphics/com.sun.javafx.tk.quantum.GlassViewEventHandler$MouseEventNotification.run(GlassViewEventHandler.java:411)
	at javafx.graphics/com.sun.javafx.tk.quantum.GlassViewEventHandler$MouseEventNotification.run(GlassViewEventHandler.java:301)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:399)
	at javafx.graphics/com.sun.javafx.tk.quantum.GlassViewEventHandler.lambda$handleMouseEvent$2(GlassViewEventHandler.java:450)
	at javafx.graphics/com.sun.javafx.tk.quantum.QuantumToolkit.runWithoutRenderLock(QuantumToolkit.java:424)
	at javafx.graphics/com.sun.javafx.tk.quantum.GlassViewEventHandler.handleMouseEvent(GlassViewEventHandler.java:449)
	at javafx.graphics/com.sun.glass.ui.View.handleMouseEvent(View.java:557)
	at javafx.graphics/com.sun.glass.ui.View.notifyMouse(View.java:943)
	at javafx.graphics/com.sun.glass.ui.mac.MacView.notifyMouse(MacView.java:127)
Caused by: java.lang.reflect.InvocationTargetException
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
	at com.sun.javafx.reflect.Trampoline.invoke(MethodUtil.java:77)
	at jdk.internal.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
	at javafx.base/com.sun.javafx.reflect.MethodUtil.invoke(MethodUtil.java:275)
	at javafx.fxml/com.sun.javafx.fxml.MethodHelper.invoke(MethodHelper.java:84)
	at javafx.fxml/javafx.fxml.FXMLLoader$MethodHandler.invoke(FXMLLoader.java:1854)
	... 40 more
Caused by: java.lang.NoClassDefFoundError: Could not initialize class uk.yermak.audiobookconverter.Platform
	at uk.yermak.audiobookconverter.fx.DialogHelper.selectFilesDialog(DialogHelper.java:55)
	at uk.yermak.audiobookconverter.fx.FilesController.selectFiles(FilesController.java:212)
	... 51 more ```
@yermak
Copy link
Owner

yermak commented Apr 24, 2023

@red-ochre
I suspect it's due to changes in security model on Mac, which dependant on MacOs version not on hardware.
As a heads-up, I'm working on pure native version for Mac to overcome all those problems (I faced many others), as I tired to fight with Mac specific issues in current implementation - I spent all might time on mac specific issues.
Mac version will be launched very soon, it will be very basic at the begining, but hopefully all those issues will be not relevant.

I'm sorry that you facing those issues now, you need to look for workaround for now.

@red-ochre
Copy link
Author

red-ochre commented May 2, 2023

Thanks for your response, @yermak.
I'm happy that you are working on a Mac version—very happy!
My current work-around is that I have an older MacBook Air that I run Win10 on under VM and then use AudioBookConverter from there. It works but this the last thing that I use Win10 for, so when we have AudioBookConverter for Mac, I can stop using Win10 altogether.

Thanks again for a great product.

For what it's worth:
My use case is that I get my audiobooks in multiple mp3 files format. I use Apple's Music.app to convert them to m4a using their voice filter (I find that it gives a very clear voice reproduction) and then use AudioBookConverter to combine them all into one m4b with a chapter mark at the boundaries where two files are joined together. I then store and catalogue all my audiobooks in calibre, where I can add lots of extra details about each book. It works well for me.

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