File Save / Save As Failing

Bug #512547 reported by Pedram Amini
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
SikuliX
In Progress
Medium
RaiMan

Bug Description

Running on Win7-64bit with Java 1.6.17-32bit. Clicking either Save or Save As immediately generates errors:

[sikuli] FileAction.doSave
java.lang.reflect.InvocationTargetException
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
 at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
 at java.lang.reflect.Method.invoke(Unknown Source)
 at edu.mit.csail.uid.SikuliIDE$MenuAction.actionPerformed(SikuliIDE.java:466)
 at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
 at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
 at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
 at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
 at javax.swing.AbstractButton.doClick(Unknown Source)
 at javax.swing.plaf.basic.BasicMenuItemUI.doClick(Unknown Source)
 at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(Unknown Source)
 at java.awt.Component.processMouseEvent(Unknown Source)
 at javax.swing.JComponent.processMouseEvent(Unknown Source)
 at java.awt.Component.processEvent(Unknown Source)
 at java.awt.Container.processEvent(Unknown Source)
 at java.awt.Component.dispatchEventImpl(Unknown Source)
 at java.awt.Container.dispatchEventImpl(Unknown Source)
 at java.awt.Component.dispatchEvent(Unknown Source)
 at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
 at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
 at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
 at java.awt.Container.dispatchEventImpl(Unknown Source)
 at java.awt.Window.dispatchEventImpl(Unknown Source)
 at java.awt.Component.dispatchEvent(Unknown Source)
 at java.awt.EventQueue.dispatchEvent(Unknown Source)
 at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
 at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
 at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
 at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
 at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
 at java.awt.EventDispatchThread.run(Unknown Source)
Caused by: java.lang.ArrayIndexOutOfBoundsException: 3184
 at sun.awt.shell.Win32ShellFolder2.getFileChooserIcon(Unknown Source)
 at sun.awt.shell.Win32ShellFolderManager2.get(Unknown Source)
 at sun.awt.shell.ShellFolder.get(Unknown Source)
 at com.sun.java.swing.plaf.windows.WindowsLookAndFeel$LazyWindowsIcon.createValue(Unknown Source)
 at javax.swing.UIDefaults.getFromHashtable(Unknown Source)
 at javax.swing.UIDefaults.get(Unknown Source)
 at javax.swing.MultiUIDefaults.get(Unknown Source)
 at javax.swing.UIDefaults.getIcon(Unknown Source)
 at javax.swing.UIManager.getIcon(Unknown Source)
 at javax.swing.plaf.basic.BasicFileChooserUI.installIcons(Unknown Source)
 at javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(Unknown Source)
 at javax.swing.plaf.basic.BasicFileChooserUI.installUI(Unknown Source)
 at com.sun.java.swing.plaf.windows.WindowsFileChooserUI.installUI(Unknown Source)
 at javax.swing.JComponent.setUI(Unknown Source)
 at javax.swing.JFileChooser.updateUI(Unknown Source)
 at javax.swing.JFileChooser.setup(Unknown Source)
 at javax.swing.JFileChooser.<init>(Unknown Source)
 at javax.swing.JFileChooser.<init>(Unknown Source)
 at edu.mit.csail.uid.SikuliPane.saveAsFile(SikuliPane.java:166)
 at edu.mit.csail.uid.SikuliPane.saveFile(SikuliPane.java:158)
 at edu.mit.csail.uid.SikuliIDE$FileAction.doSave(SikuliIDE.java:568)
 ... 32 more

Tags: idemenu
Revision history for this message
josh (jowillia) wrote :

Same issue occurs on OS X 10.5.8, using 10.4 Build. The stack trace is a bit different:

java.io.FileNotFoundException: /Users/jowillia/temp (No such file or directory)
 at java.io.FileOutputStream.open(Native Method)
 at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
 at java.io.FileOutputStream.<init>(FileOutputStream.java:70)
 at java.io.FileWriter.<init>(FileWriter.java:46)
 at edu.mit.csail.uid.SikuliPane.saveAsFile(SikuliPane.java:126)
 at edu.mit.csail.uid.SikuliPane.saveFile(SikuliPane.java:100)
 at edu.mit.csail.uid.SikuliIDE$FileAction.doSave(SikuliIDE.java:417)
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
 at java.lang.reflect.Method.invoke(Method.java:592)
 at edu.mit.csail.uid.SikuliIDE$MenuAction.actionPerformed(SikuliIDE.java:350)
 at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1882)
 at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:22save to /Users/jowillia/temp/
02)
 at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
 at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
 at javax.swing.AbstractButton.doClick(AbstractButton.java:334)
 at apple.laf.ScreenMenuItem.actionPerformed(ScreenMenuItem.java:95)
 at java.awt.MenuItem.processActionEvent(MenuItem.java:597)
 at java.awt.MenuItem.processEvent(MenuItem.java:556)
 at java.awt.MenuComponent.dispatchEventImpl(MenuComponent.java:298)
 at java.awt.MenuComponent.dispatchEvent(MenuComponent.java:286)
 at java.awt.EventQueue.dispatchEvent(EventQueue.java:466)
 at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:269)
 at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
 at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:184)
 at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:176)
 at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)

But there is a work around. If you end the file in .sikuli, the the file is created and the script and images are stored. This of course only tested on OS X.

RaiMan (raimund-hocke)
Changed in sikuli:
status: New → In Progress
importance: Undecided → Medium
assignee: nobody → RaiMan (raimund-hocke)
tags: added: idemenu
Revision history for this message
Shawn Robertson (shawn-robertson) wrote :

I am currently on 1.1.0 but this also happened on 1.0.1 in another manner.

in 1.1.0 sometimes when i try to save using File>save or ctrl+S, the message box states:

[error] IDE: Problem when trying to invoke menu action doSave Error: null

sometimes it actually saves anyways after i close out and say no to save changes and reopen and the changes are saved but other times it does not always save.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.