Uncaught exception occurred in Thread[#57,JavaFX Application Thread,5,main]

When trying to save my bibliography with save actions, I receive the following error:

Uncaught exception occurred in Thread[#57,JavaFX Application Thread,5,main]

URLDecoder: Illegal hex characters in escape (%) pattern - Error at index 0 in: “),”

The exception stracktrace was:
java.lang.IllegalArgumentException: URLDecoder: Illegal hex characters in escape (%) pattern - Error at index 0 in: "),"
	at java.base/java.net.URLDecoder.decode(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.logic.formatter.bibtexfields.CleanupUrlFormatter.format(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.logic.cleanup.FieldFormatterCleanup.cleanupSingleField(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.logic.cleanup.FieldFormatterCleanup.cleanupAllFields(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.logic.cleanup.FieldFormatterCleanup.cleanup(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.logic.cleanup.FieldFormatterCleanups.applyAllActions(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.logic.cleanup.FieldFormatterCleanups.applySaveActions(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.logic.exporter.BibDatabaseWriter.lambda$applySaveActions$0(Unknown Source)
	at java.base/java.util.Optional.ifPresent(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.logic.exporter.BibDatabaseWriter.applySaveActions(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.logic.exporter.BibDatabaseWriter.savePartOfDatabase(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.logic.exporter.BibDatabaseWriter.saveDatabase(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.gui.exporter.SaveDatabaseAction.saveDatabase(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.gui.exporter.SaveDatabaseAction.save(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.gui.exporter.SaveDatabaseAction.save(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.gui.exporter.SaveDatabaseAction.save(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.gui.exporter.SaveAction.execute(Unknown Source)
	at org.jabref@5.15.60000/org.jabref.gui.actions.JabRefAction.lambda$new$1(Unknown Source)
	at org.jabref.merged.module@5.15.60000/org.controlsfx.control.action.Action.handle(Unknown Source)
	at org.jabref.merged.module@5.15.60000/org.controlsfx.control.action.Action.handle(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.CompositeEventHandler.dispatchBubblingEvent(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.EventUtil.fireEventImpl(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.EventUtil.fireEvent(Unknown Source)
	at javafx.base@22.0.1/javafx.event.Event.fireEvent(Unknown Source)
	at javafx.controls@22.0.1/javafx.scene.control.MenuItem.fire(Unknown Source)
	at javafx.controls@22.0.1/com.sun.javafx.scene.control.ControlAcceleratorSupport.lambda$doAcceleratorInstall$1(Unknown Source)
	at javafx.graphics@22.0.1/com.sun.javafx.scene.KeyboardShortcutsHandler.processAccelerators(Unknown Source)
	at javafx.graphics@22.0.1/com.sun.javafx.scene.KeyboardShortcutsHandler.dispatchBubblingEvent(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.CompositeEventDispatcher.dispatchBubblingEvent(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.EventUtil.fireEventImpl(Unknown Source)
	at javafx.base@22.0.1/com.sun.javafx.event.EventUtil.fireEvent(Unknown Source)
	at javafx.base@22.0.1/javafx.event.Event.fireEvent(Unknown Source)
	at javafx.graphics@22.0.1/javafx.scene.Scene.processKeyEvent(Unknown Source)
	at javafx.graphics@22.0.1/javafx.scene.Scene$ScenePeerListener.keyEvent(Unknown Source)
	at javafx.graphics@22.0.1/com.sun.javafx.tk.quantum.GlassViewEventHandler$KeyEventNotification.run(Unknown Source)
	at javafx.graphics@22.0.1/com.sun.javafx.tk.quantum.GlassViewEventHandler$KeyEventNotification.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Unknown Source)
	at javafx.graphics@22.0.1/com.sun.javafx.tk.quantum.GlassViewEventHandler.lambda$handleKeyEvent$1(Unknown Source)
	at javafx.graphics@22.0.1/com.sun.javafx.tk.quantum.QuantumToolkit.runWithoutRenderLock(Unknown Source)
	at javafx.graphics@22.0.1/com.sun.javafx.tk.quantum.GlassViewEventHandler.handleKeyEvent(Unknown Source)
	at javafx.graphics@22.0.1/com.sun.glass.ui.View.handleKeyEvent(Unknown Source)
	at javafx.graphics@22.0.1/com.sun.glass.ui.View.notifyKey(Unknown Source)
	at javafx.graphics@22.0.1/com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
	at javafx.graphics@22.0.1/com.sun.glass.ui.win.WinApplication.lambda$runLoop$3(Unknown Source)
	at java.base/java.lang.Thread.run(Unknown Source)

The save actions I am trying to use are:

  • escape ampersands
  • identity
  • normalize page numbers
  • escape ampersands
  • html to latex
  • unicode to latex
  • cleanup URL
  • latex cleanup

Here is my JabRef version:

JabRef 5.15--2024-07-10--1eb3493
Windows 11 10.0 amd64 
Java 21.0.2 
JavaFX 22.0.1+7

Thanks in advance!

Thanks for the report. The erorr comes from the “cleanup url action” This looks like some invalid character in the URL/file field in your BibTeX data:
It would help us to see the whole line where it happens.
To find this line, you can open the bibfile with a text editor, e.g., Notepad++ that supports regex search and enter to find the line:

%(?![0-9a-fA-F]{2})

If you are unable to do this you can also send your bib file to web@jabref.org (we will treat it confidentially)

Thanks very much for your prompt response. When I searched the (large) .bib file, it finds many instances of % symbols. As far as I can tell, all of them are escaped.

If it’s helpful, my .bib file can be downloaded at the following location:

(The raw file is here: https://raw.githubusercontent.com/isaactpetersen/Principles-Psychological-Assessment/refs/heads/main/references.bib)