End Logfile dump error V3.3.1

Hello,
I have been saving logfiles into a dropbox folder for over a week with 3.3.1 before this occurred.
While saving my logfile with the end logfile command I got a java dump (see attached). Vassal managed to save the log in zip format file with some random ID, but not rename it to the vlog format with the file name I had selected. I renamed the zip and replayed it. It was correct.

Kr
Claudio

java.io.IOException: Unable to overwrite D:\Dropbox\GTS Steven Claudio\Saga Jun06_2100 58C.vlog: file does not exist. Data written to D:\Dropbox\GTS Steven Claudio\tmp18363577742719448906.zip instead.
at VASSAL.tools.io.ZipArchive.writeToDisk(ZipArchive.java:476)
at VASSAL.tools.io.ZipArchive.close(ZipArchive.java:385)
at VASSAL.build.module.BasicLogger.write(BasicLogger.java:323)
at VASSAL.build.module.BasicLogger$4.actionPerformed(BasicLogger.java:479)
at java.desktop/javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at java.desktop/javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
at java.desktop/javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at java.desktop/javax.swing.DefaultButtonModel.setPressed(Unknown Source)
at java.desktop/javax.swing.AbstractButton.doClick(Unknown Source)
at java.desktop/javax.swing.plaf.basic.BasicMenuItemUI.doClick(Unknown Source)
at java.desktop/javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(Unknown Source)
at java.desktop/java.awt.Component.processMouseEvent(Unknown Source)
at java.desktop/javax.swing.JComponent.processMouseEvent(Unknown Source)
at java.desktop/java.awt.Component.processEvent(Unknown Source)
at java.desktop/java.awt.Container.processEvent(Unknown Source)
at java.desktop/java.awt.Component.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.Container.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.Component.dispatchEvent(Unknown Source)
at java.desktop/java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.desktop/java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.desktop/java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.desktop/java.awt.Container.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.Window.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.Component.dispatchEvent(Unknown Source)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
at java.base/java.security.AccessController.doPrivileged(Unknown Source)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.desktop/java.awt.EventQueue$5.run(Unknown Source)
at java.desktop/java.awt.EventQueue$5.run(Unknown Source)
at java.base/java.security.AccessController.doPrivileged(Unknown Source)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.desktop/java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.run(Unknown Source)
Caused by: java.io.FileNotFoundException: File does not exist: D:\Dropbox\GTS Steven Claudio\Saga Jun06_2100 58C.vlog
at org.apache.commons.io.FileUtils.forceDelete(FileUtils.java:2396)
at VASSAL.tools.io.ZipArchive.writeToDisk(ZipArchive.java:458)
… 40 more

Very likely a manifestation of 13014. I think there’s some current movement on getting rid of the closeQuietly’s that are suspected to be causing the problem.

vassalengine.org/tracker/sho … i?id=13014

This particular one is not related to the closeQueitly() bugs, this one is due to bad code in the writeToDisk() method:

    if (!tmpFile.renameTo(archiveFile)) {
      try {
        FileUtils.forceDelete(archiveFile); <-- this one throws the exception saying "java.io.FileNotFoundException: File does not exist"

Failing to rename A to B using File.renameTo() may have various reasons, and it may well be that after such a failure B does not exist. The Vassal code does not account for this. This whole code with the file operations should probably be rewritten to use the more modern and way more reliable java.nio.file.Files.move() method.

Thus spake Cattlesquat:

Very likely a manifestation of 13014. I think there’s some current
movement on getting rid of the closeQuietly’s that are suspected to be
causing the problem.

The uses of closeQuietly() aren’t causing the problem; if they’re
involved, they’re hiding the exception.


J.

Thus spake Flint1b:

This particular one is not related to the closeQueitly() bugs, this one
is due to bad code in the writeToDisk() method:

Code:

if (!tmpFile.renameTo(archiveFile)) {
  try {
    FileUtils.forceDelete(archiveFile); <-- this one throws the

exception saying “java.io.FileNotFoundException: File does not exist”

Failing to rename A to B using File.renameTo() may have various reasons,
and it may well be that after such a failure B does not exist. The
Vassal code does not account for this.

Yes, it does. The code in the catch block just below this is there
precisely to determine why the failure happened.


J.

Nononono, it does write a nice error message but it does not try to resolve the problem, which in this case is not even a problem.

What the code does:

  1. tmpFile.rename(archiveFile) ← fails for some reason, can be various reasons as described in its javadoc
  2. forceDelete(archiveFile) ← here the code assumes that forceDelete() finds a file to delete
  3. moveFile(tmpFile, archiveFile)

If forceDelete() has no file to delete then all is well, we are not in an error situation and can proceed with moveFile().

Something like this:

if (archiveFile.exists()) {
forceDelete(archiveFile);
}
moveFile(tmpFile, archiveFile);

Claudio, we’ve changed the bit of code which was throwing an exception for you. What does the 3.3.2-380-g5e14b788 build do when you try that?

vassalengine.org/~uckelman/tmp/

Hello Joel,
Not sure how I can reproduce the error. It occured sporadically, and I have no real clue of what triggered it. I suspect that when working on a Dropbox or Google Drive synchronized folder, something happens that ‘hides’ the file for a few instants, which caused the error described above.

I will do some tests to see if I can make the error appear in 3.2.17 first.

I found a way to reproduce the bug or something similar:

Managed to generate an error when

  1. A preexisting vsav or vlog file exists.
  2. Open that file in the module
  3. Open the vsav or vlog with 7zip
  4. Save the game with the same name as in 1) or begin a logfile with same name as in 1 do 1 action then end log
    Error occurs.

Not sure this is the same error as the one with the Dropbox ifolders I reported at the top of this thread, here is the log
Here the dump occurs because vassal is unable to delete the target file. THe error log above was occurring because vassal was not finding the target file anymore after having created it.

2020-07-20 21:59:39,534 [0-main] INFO VASSAL.launch.StartUp - Starting
2020-07-20 21:59:39,550 [0-main] INFO VASSAL.launch.StartUp - OS Windows 10 10.0
2020-07-20 21:59:39,550 [0-main] INFO VASSAL.launch.StartUp - Java version 14.0.1
2020-07-20 21:59:39,550 [0-main] INFO VASSAL.launch.StartUp - VASSAL version 3.3.2-380-g5e14b788a42b
2020-07-20 21:59:39,863 [0-AWT-EventQueue-0] INFO VASSAL.launch.ModuleManager - Manager
2020-07-20 22:00:19,956 [0-SwingWorker-pool-2-thread-1] INFO VASSAL.launch.AbstractLaunchAction - Loading module file D:\Vassal\GTS\TGD_v189.vmod
2020-07-20 22:00:21,080 [0-SwingWorker-pool-2-thread-1] INFO VASSAL.launch.TilingHandler - No images to tile.
2020-07-20 22:00:21,080 [0-SwingWorker-pool-2-thread-1] INFO VASSAL.launch.AbstractLaunchAction - Loading module The Greatest Day: Sword, Juno and Gold Beaches
2020-07-20 22:00:21,111 [0-SwingWorker-pool-2-thread-1] INFO VASSAL.tools.io.ProcessLauncher - launching C:\Program Files\VASSAL-3.3.2-380-g5e14b788\jre\bin\java -Xms256M -Xmx2048M -DVASSAL.id=1 -DVASSAL.port=59462 -Duser.home=C:\Users\claud -Duser.dir=C:\Program Files\VASSAL-3.3.2-380-g5e14b788 -cp lib\Vengine.jar VASSAL.launch.Player --load – D:\Vassal\GTS\TGD_v189.vmod
2020-07-20 22:00:22,472 [1-main] INFO VASSAL.launch.StartUp - Starting
2020-07-20 22:00:22,487 [1-main] INFO VASSAL.launch.StartUp - OS Windows 10 10.0
2020-07-20 22:00:22,487 [1-main] INFO VASSAL.launch.StartUp - Java version 14.0.1
2020-07-20 22:00:22,487 [1-main] INFO VASSAL.launch.StartUp - VASSAL version 3.3.2-380-g5e14b788a42b
2020-07-20 22:00:22,487 [1-main] INFO VASSAL.launch.Launcher - Player
2020-07-20 22:00:24,708 [1-IconFactory-preload] INFO VASSAL.tools.icon.IconFactory - VASSAL images folder found at jar:file:/C:/Program%20Files/VASSAL-3.3.2-380-g5e14b788/lib/Vengine.jar!/images/
2020-07-20 22:00:24,713 [1-IconFactory-preload] INFO VASSAL.tools.icon.IconFactory - Icon family VASSAL created for VASSAL.svg
2020-07-20 22:00:24,713 [1-IconFactory-preload] INFO VASSAL.tools.icon.IconFactory - Icon family VASSAL-jabber created for VASSAL-jabber.png
2020-07-20 22:00:24,713 [1-IconFactory-preload] INFO VASSAL.tools.icon.IconFactory - Icon family network-idle created for network-idle.svg
2020-07-20 22:00:24,713 [1-IconFactory-preload] INFO VASSAL.tools.icon.IconFactory - Icon family yes created for yes.svg
2020-07-20 22:00:24,713 [1-IconFactory-preload] INFO VASSAL.tools.icon.IconFactory - Icon family go-down created for go-down.svg
2020-07-20 22:00:24,713 [1-IconFactory-preload] INFO VASSAL.tools.icon.IconFactory - Icon family bug created for bug.svg
2020-07-20 22:00:24,713 [1-IconFactory-preload] INFO VASSAL.tools.icon.IconFactory - Icon family no created for no.svg
2020-07-20 22:00:24,713 [1-IconFactory-preload] INFO VASSAL.tools.icon.IconFactory - Icon family calculator created for calculator.svg
2020-07-20 22:00:24,714 [1-IconFactory-preload] INFO VASSAL.tools.icon.IconFactory - Icon family jabber created for jabber.png
2020-07-20 22:00:24,714 [1-IconFactory-preload] INFO VASSAL.tools.icon.IconFactory - Icon family go-up created for go-up.svg
2020-07-20 22:00:24,714 [1-IconFactory-preload] INFO VASSAL.tools.icon.IconFactory - Icon family network-server created for network-server.svg
2020-07-20 22:00:27,520 [1-AWT-EventQueue-0] WARN VASSAL.launch.BasicModule - The Greatest Day: Sword, Juno and Gold Beaches version 1.8.9
2020-07-20 22:00:27,551 [1-AWT-EventQueue-0] ERROR VASSAL.i18n.BundleHelper - No Translation: Wizard.Next_mnemonic
2020-07-20 22:00:27,551 [1-AWT-EventQueue-0] ERROR VASSAL.i18n.BundleHelper - No Translation: Wizard.Prev_mnemonic
2020-07-20 22:00:27,551 [1-AWT-EventQueue-0] ERROR VASSAL.i18n.BundleHelper - No Translation: Wizard.Finish_mnemonic
2020-07-20 22:00:27,551 [1-AWT-EventQueue-0] ERROR VASSAL.i18n.BundleHelper - No Translation: Wizard.Cancel_mnemonic
2020-07-20 22:13:36,944 [1-Thread-0] WARN VASSAL.tools.ErrorDialog - Image not found: marker-focus.png
2020-07-20 22:13:38,251 [1-Thread-0] INFO VASSAL.script.ExpressionInterpreter - Attempting to load /VASSAL/script/init_expression.bsh URI generated=jar:file:/C:/Program%20Files/VASSAL-3.3.2-380-g5e14b788/lib/Vengine.jar!/VASSAL/script/init_expression.bsh
2020-07-20 22:14:14,432 [1-AWT-EventQueue-0] ERROR VASSAL.tools.ProblemDialog -
java.io.IOException: Unable to overwrite D:\GoogleDrive\Imprim\test8.vlog: Unable to delete file: D:\GoogleDrive\Imprim\test8.vlog Data written to D:\GoogleDrive\Imprim\tmp4662544719032062750.zip instead.
at VASSAL.tools.io.ZipArchive.writeToDisk(ZipArchive.java:461)
at VASSAL.tools.io.ZipArchive.close(ZipArchive.java:383)
at VASSAL.build.module.GameState.saveGame(GameState.java:755)
at VASSAL.build.module.GameState.saveGameAs(GameState.java:545)
at VASSAL.build.module.GameState$3.actionPerformed(GameState.java:143)
at java.desktop/javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at java.desktop/javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
at java.desktop/javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at java.desktop/javax.swing.DefaultButtonModel.setPressed(Unknown Source)
at java.desktop/javax.swing.AbstractButton.doClick(Unknown Source)
at java.desktop/javax.swing.plaf.basic.BasicMenuItemUI.doClick(Unknown Source)
at java.desktop/javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(Unknown Source)
at java.desktop/java.awt.Component.processMouseEvent(Unknown Source)
at java.desktop/javax.swing.JComponent.processMouseEvent(Unknown Source)
at java.desktop/java.awt.Component.processEvent(Unknown Source)
at java.desktop/java.awt.Container.processEvent(Unknown Source)
at java.desktop/java.awt.Component.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.Container.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.Component.dispatchEvent(Unknown Source)
at java.desktop/java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.desktop/java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.desktop/java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.desktop/java.awt.Container.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.Window.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.Component.dispatchEvent(Unknown Source)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
at java.base/java.security.AccessController.doPrivileged(Unknown Source)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.desktop/java.awt.EventQueue$5.run(Unknown Source)
at java.desktop/java.awt.EventQueue$5.run(Unknown Source)
at java.base/java.security.AccessController.doPrivileged(Unknown Source)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.desktop/java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.run(Unknown Source)
Caused by: java.io.IOException: Unable to delete file: D:\GoogleDrive\Imprim\test8.vlog
at org.apache.commons.io.FileUtils.forceDelete(FileUtils.java:1338)
at VASSAL.tools.io.ZipArchive.writeToDisk(ZipArchive.java:455)
… 41 common frames omitted
Caused by: java.nio.file.FileSystemException: D:\GoogleDrive\Imprim\test8.vlog: Le processus ne peut pas accéder au fichier car ce fichier est utilisé par un autre processus
at java.base/sun.nio.fs.WindowsException.translateToIOException(Unknown Source)
at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source)
at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source)
at java.base/sun.nio.fs.WindowsFileSystemProvider.implDelete(Unknown Source)
at java.base/sun.nio.fs.AbstractFileSystemProvider.deleteIfExists(Unknown Source)
at java.base/java.nio.file.Files.deleteIfExists(Unknown Source)
at org.apache.commons.io.file.PathUtils.deleteFile(PathUtils.java:282)
at org.apache.commons.io.file.PathUtils.delete(PathUtils.java:254)
at org.apache.commons.io.FileUtils.forceDelete(FileUtils.java:1336)
… 42 common frames omitted
2020-07-20 22:14:14,510 [1-pool-3-thread-1] ERROR VASSAL.tools.ErrorDialog -
java.lang.reflect.InvocationTargetException: null
at java.desktop/java.awt.EventQueue.invokeAndWait(Unknown Source)
at java.desktop/java.awt.EventQueue.invokeAndWait(Unknown Source)
at java.desktop/javax.swing.SwingUtilities.invokeAndWait(Unknown Source)
at VASSAL.tools.DialogUtils$1.run(DialogUtils.java:69)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.base/java.lang.Thread.run(Unknown Source)
Caused by: java.lang.NullPointerException: null
at java.desktop/javax.swing.BoxLayout.preferredLayoutSize(Unknown Source)
at java.desktop/javax.swing.plaf.basic.BasicOptionPaneUI.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.desktop/java.awt.BorderLayout.preferredLayoutSize(Unknown Source)
at java.desktop/java.awt.Container.preferredSize(Unknown Source)
at java.desktop/java.awt.Container.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.JRootPane$RootLayout.preferredLayoutSize(Unknown Source)
at java.desktop/java.awt.Container.preferredSize(Unknown Source)
at java.desktop/java.awt.Container.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.desktop/java.awt.BorderLayout.preferredLayoutSize(Unknown Source)
at java.desktop/java.awt.Container.preferredSize(Unknown Source)
at java.desktop/java.awt.Container.getPreferredSize(Unknown Source)
at net.miginfocom.swing.MigLayout.adjustWindowSize(Unknown Source)
at net.miginfocom.swing.MigLayout.layoutContainer(Unknown Source)
at net.miginfocom.swing.MigLayout.preferredLayoutSize(Unknown Source)
at java.desktop/java.awt.Container.preferredSize(Unknown Source)
at java.desktop/java.awt.Container.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.desktop/java.awt.GridBagLayout.GetLayoutInfo(Unknown Source)
at java.desktop/java.awt.GridBagLayout.getLayoutInfo(Unknown Source)
at java.desktop/java.awt.GridBagLayout.preferredLayoutSize(Unknown Source)
at java.desktop/java.awt.Container.preferredSize(Unknown Source)
at java.desktop/java.awt.Container.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.desktop/java.awt.BorderLayout.preferredLayoutSize(Unknown Source)
at java.desktop/java.awt.Container.preferredSize(Unknown Source)
at java.desktop/java.awt.Container.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.desktop/java.awt.BorderLayout.preferredLayoutSize(Unknown Source)
at java.desktop/java.awt.Container.preferredSize(Unknown Source)
at java.desktop/java.awt.Container.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.BoxLayout.checkRequests(Unknown Source)
at java.desktop/javax.swing.BoxLayout.preferredLayoutSize(Unknown Source)
at java.desktop/javax.swing.plaf.basic.BasicOptionPaneUI.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.desktop/java.awt.BorderLayout.preferredLayoutSize(Unknown Source)
at java.desktop/java.awt.Container.preferredSize(Unknown Source)
at java.desktop/java.awt.Container.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.JRootPane$RootLayout.preferredLayoutSize(Unknown Source)
at java.desktop/java.awt.Container.preferredSize(Unknown Source)
at java.desktop/java.awt.Container.getPreferredSize(Unknown Source)
at java.desktop/javax.swing.JComponent.getPreferredSize(Unknown Source)
at java.desktop/java.awt.BorderLayout.preferredLayoutSize(Unknown Source)
at java.desktop/java.awt.Container.preferredSize(Unknown Source)
at java.desktop/java.awt.Container.getPreferredSize(Unknown Source)
at java.desktop/java.awt.Window.pack(Unknown Source)
at java.desktop/javax.swing.JOptionPane.initDialog(Unknown Source)
at java.desktop/javax.swing.JOptionPane.createDialog(Unknown Source)
at java.desktop/javax.swing.JOptionPane.createDialog(Unknown Source)
at VASSAL.tools.swing.DetailsDialog.showDialog(DetailsDialog.java:99)
at VASSAL.tools.ProblemDialog$4.run(ProblemDialog.java:273)
at java.desktop/java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
at java.base/java.security.AccessController.doPrivileged(Unknown Source)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.desktop/java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.run(Unknown Source)
2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - java.util.concurrent.ExecutionException: java.io.IOException: java.lang.NumberFormatException: For input string: “”

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.util.concurrent.FutureTask.report(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.util.concurrent.FutureTask.get(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/javax.swing.SwingWorker.get(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at VASSAL.tools.BugDialog$SendRequest.done(BugDialog.java:563)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/javax.swing.SwingWorker$5.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/javax.swing.SwingWorker$DoSubmitAccumulativeRunnable.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/sun.swing.AccumulativeRunnable.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/javax.swing.SwingWorker$DoSubmitAccumulativeRunnable.actionPerformed(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/javax.swing.Timer.fireActionPerformed(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/javax.swing.Timer$DoPostEvent.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.event.InvocationEvent.dispatch(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventQueue.dispatchEventImpl(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventQueue$4.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventQueue$4.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.security.AccessController.doPrivileged(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventQueue.dispatchEvent(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.WaitDispatchSupport$2.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.WaitDispatchSupport$4.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.WaitDispatchSupport$4.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.security.AccessController.doPrivileged(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.WaitDispatchSupport.enter(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.Dialog.show(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.Component.show(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.Component.setVisible(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.Window.setVisible(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.Dialog.setVisible(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at VASSAL.tools.BugDialog.setVisible(BugDialog.java:447)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at VASSAL.tools.ErrorDialog$1.run(ErrorDialog.java:94)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.event.InvocationEvent.dispatch(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventQueue.dispatchEventImpl(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventQueue$4.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventQueue$4.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.security.AccessController.doPrivileged(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventQueue.dispatchEvent(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/java.awt.EventDispatchThread.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - Caused by: java.io.IOException: java.lang.NumberFormatException: For input string: “”

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at VASSAL.tools.BugUtils.sendBugReport(BugUtils.java:37)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at VASSAL.tools.BugDialog$SendRequest.doInBackground(BugDialog.java:549)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at VASSAL.tools.BugDialog$SendRequest.doInBackground(BugDialog.java:530)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/javax.swing.SwingWorker$1.call(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.util.concurrent.FutureTask.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.desktop/javax.swing.SwingWorker.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.lang.Thread.run(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - Caused by: java.lang.NumberFormatException: For input string: “”

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.lang.NumberFormatException.forInputString(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.lang.Integer.parseInt(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at java.base/java.lang.Integer.parseInt(Unknown Source)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - at VASSAL.tools.BugUtils.sendBugReport(BugUtils.java:32)

2020-07-20 22:17:49,015 [1-AWT-EventQueue-0] WARN VASSAL.tools.logging.LoggedOutputStream - … 8 more

This is a good way to simulate a process that forcefully keeps the old file open and prevents any further writing into it, or deleting it and replacing with a new file.

Although in that particular case, nothing we can do is going to help. We can only replace the old file with the new one if the user allows us to :smiley:

But we used to put up a much friendlier error in the “just couldn’t write the file” or “just couldn’t rename the tmp file” cases, not the normal “Vassal has encountered an error. Click here for huge scary stack trace” error.

Thus spake Cattlesquat:

But we used to put up a much friendlier error in the “just couldn’t
write the file” or “just couldn’t rename the tmp file” cases, not the
normal “Vassal has encountered an error. Click here for huge scary stack
trace” error.

I’m not following here. What makes you think we’re showing a different
error dialog than before?


J.

Here is friendlier file-write failure from Vassal 3.2.17 (you can repro by editing a module, opening the module in 7 zip, and then trying to save the module from the module editor)

[attachment=1]friendlyfail.png[/attachment]

Now here is what happens when you do the exact same thing in the 3.3 line…

[attachment=0]unfriendlyfail.png[/attachment]

Somewhere along the way we lost a path that went to a friendlier write message.

Brian

Isn’t the second one friendlier? Both have the stacktrace hidden behind “show details” but the first has this intimidating red cross, says “unable to do something” which could also be an accusation of the user, and just an “OK” button, while the second one has a cute little bug, none of the alarming red colors, says “we had an internal problem, nothing to do with you dear user” and even offers a way to communicate with the Vassal team.

Agree with you on the ‘friendliness’ measurements.

The main problem with the second version is that it pushes a new bug report into bugzilla for a something that isn’t really a bug.

Something between the two would be better. No bug report option but less intimidating and it should rename the tmp file to something better (gamemodule-copy23vmod instead of TMP122323j2jj3.zip) and tell the user where to find it.

I apparently get a mostly blank crash window when I get VASSAL to crash…see my post in the [url]https://forum.vassalengine.org/t/surface-not-cachable-3-3-2/10910/1] thread…

Edit: Okay, realized I should probably try the latest release (3.3.2), and it populates the error window correctly. So, false alarm, I guess.

Thus spake Cattlesquat:

Here is friendlier file-write failure from Vassal 3.2.17 (you can repro
by editing a module, opening the module in 7 zip, and then trying to
save the module from the module editor)

friendlyfail.png

Now here is what happens when you do the exact same thing in the 3.3
line…

unfriendlyfail.png

Somewhere along the way we lost a path that went to a friendlier write
message.

Am I the only one who read the stack trace? :slight_smile:

The bug dialog was not displayed for the write error. The bug dialog was
displayed because there was an NullPointerException when trying to display
the write error dialog.


J.

Haha I probably got to “Error.ProblemDialog” and stopped reading.

But since we’ve got a discussion of error UI flow going, some opinions!
(1) Apart from the scary-red-X, the first dialog box is more “normal user friendly” because it (a) explains a fairly specific problem in fairly common English, (b) doesn’t ask scary “send-in-a-bug-report” questions which make it sound like Vassal has crashed, and (c) doesn’t follow up with the “and now Vassal may or may not be stable any more” message.
(2) But yes let’s get rid of the red X!
(3) And absolutely yes, let’s go to a better filename (approximating our desired filename with a .vmod extension). Operating systems usually do things like putting a (1) and then a (2) etc after the name.
(4) And preferably make the explanation a little better here, like a reasons-could-include-this-file-being-open-in-another-window-or-app.

Thus spake Cattlesquat:

(c) doesn’t
follow up with the “and now Vassal may or may not be stable any more”
message.

That’s true in the cases when the bug report dialog is shown.

(2) But yes let’s get rid of the red X!

What’s done on Windows natively these days when a file can’t be written?

(3) And absolutely yes, let’s go to a better filename (approximating our
desired filename with a .vmod extension). Operating systems usually do
things like putting a (1) and then a (2) etc after the name.
(4) And preferably make the explanation a little better here, like a
reasons-could-include-this-file-being-open-in-another-window-or-app.

Open a ticket?


J.

It’s very app-dependent and situation-dependent. Like Notepad trying to save a file on top of one that’s already open says “The process cannot access the file because it is being used by another process.”. Whereas if you’re in the “file explorer” (i.e. a folder) and have a copied file in your clipboard and try to paste on top of an existing file of the same name it will add " - Copy" to the end of the filename, and after that it goes to " - Copy(2)" etc.

Will do – now open as 13204 (vassalengine.org/tracker/sho … i?id=13204). I’m assuming that getting this particular situation back to displaying our traditional file-write problem dialog is already being handled separately, unless you let me know you want me to open one for that too.

Actually I’m going to open a bug 13205 (vassalengine.org/tracker/sho … i?id=13205) for the NPE displaying the file dialog.

Brian