Hi, could you submit a bug request ?


2012/11/2 Matthew Zaleski <mzaleski99@gmail.com>


On Fri, Nov 2, 2012 at 1:55 PM, Matthew Zaleski <mzaleski99@gmail.com> wrote:
I've had this problem off and on, but now have a reproducible test case:

1. Open jEdit.  I have a large number of buffers open from previoius session.
2. Call jEdit from command line to open a previously unopen file (i.e. a new file to work on).
3. Choose File|Save As... and give file a new name.
4. Move somewhere in middle of buffer.
5. Use delete lines macro several times (Edit|Text|Delete Lines)
6. Attempt undo (Edit|Undo)

Buffer view is trashed (not properly redrawn) and error dialog appears.  I've included the jEdit log for reference.  Any thoughts as to what my next steps should be?  I'm a bit confused by the actual failure as Delete Lines is a built-in function rather than my rather poor attempts to create my own.


1:37:02 PM [main] [message] Log: When reporting bugs, please include the following information:
1:37:02 PM [main] [message] Log: java.version=1.6.0_22
1:37:02 PM [main] [message] Log: java.vm.version=17.1-b03
1:37:02 PM [main] [message] Log: java.vm.name=Java HotSpot(TM) 64-Bit Server VM
1:37:02 PM [main] [message] Log: java.runtime.version=1.6.0_22-b04
1:37:02 PM [main] [message] Log: java.runtime.name=Java(TM) SE Runtime Environment
1:37:02 PM [main] [message] Log: java.vendor=Sun Microsystems Inc.
1:37:02 PM [main] [message] Log: java.compiler=null
1:37:02 PM [main] [message] Log: os.name=Windows 7
1:37:02 PM [main] [message] Log: os.version=6.1
1:37:02 PM [main] [message] Log: os.arch=amd64
1:37:02 PM [main] [message] Log: user.home=C:\Users\mzaleski
1:37:02 PM [main] [message] Log: java.home=C:\Program Files\Java\jre1.6.0_22
1:37:02 PM [main] [message] Log: java.class.path=C:\Program Files\jEdit\jedit.jar
1:37:02 PM [main] [message] jEdit: starting with command line arguments: -reuseview



1:39:35 PM [jEdit I/O #2] [debug] WorkThread: Running in work thread: [id=11,run=org.gjt.sp.jedit.bufferio.BufferSaveRequest[Report.m (C:\vehdyn_toolbox\R2011b\VehDyn.mks\CR\@vdCR\)]]
1:39:35 PM [AWT-EventQueue-0] [debug] EditBus: BufferUpdate[what=PROPERTIES_CHANGED,view=null,source=Report1.m (C:\vehdyn_toolbox\R2011b\VehDyn.mks\CR\@vdCR\)]
1:39:35 PM [AWT-EventQueue-0] [debug] EditBus: BufferUpdate[what=DIRTY_CHANGED,view=org.gjt.sp.jedit.View[active],source=Report1.m (C:\vehdyn_toolbox\R2011b\VehDyn.mks\CR\@vdCR\)]
1:39:35 PM [AWT-EventQueue-0] [debug] EditBus: BufferUpdate[what=SAVED,view=org.gjt.sp.jedit.View[active],source=Report1.m (C:\vehdyn_toolbox\R2011b\VehDyn.mks\CR\@vdCR\)]
1:39:35 PM [AWT-EventQueue-0] [debug] EditBus: VFSUpdate[path=C:\vehdyn_toolbox\R2011b\VehDyn.mks\CR\@vdCR,source=null]
1:39:35 PM [AWT-EventQueue-0] [debug] EditBus: VFSUpdate[path=C:\vehdyn_toolbox\R2011b\VehDyn.mks\CR\@vdCR\#Report1.m#save#,source=null]
1:39:35 PM [AWT-EventQueue-0] [debug] EditBus: VFSUpdate[path=C:\vehdyn_toolbox\R2011b\VehDyn.mks\CR\@vdCR\Report1.m,source=null]
1:39:35 PM [AWT-EventQueue-0] [debug] EditBus: DynamicMenuChanged[menu=recent-files,source=null]
1:39:37 PM [AWT-EventQueue-0] [debug] EditBus: PositionChanging[what=POSITION_CHANGING,source=org.gjt.sp.jedit.EditPane[active]]
1:39:38 PM [AWT-EventQueue-0] [debug] EditBus: BufferUpdate[what=DIRTY_CHANGED,view=null,source=Report1.m (C:\vehdyn_toolbox\R2011b\VehDyn.mks\CR\@vdCR\)]
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction: java.lang.InternalError: Unbalanced begin/endCompoundEdit()
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.buffer.UndoManager.undo(UndoManager.java:71)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.buffer.JEditBuffer.undo(JEditBuffer.java:2092)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.lang.reflect.Method.invoke(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.bsh.Reflect.invokeMethod(Reflect.java:134)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.bsh.Reflect.invokeObjectMethod(Reflect.java:80)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.bsh.Name.invokeMethod(Name.java:855)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.bsh.BSHMethodInvocation.eval(BSHMethodInvocation.java:75)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:102)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:47)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.bsh.BSHBlock.evalBlock(BSHBlock.java:130)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.bsh.BSHBlock.eval(BSHBlock.java:80)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.bsh.BshMethod.invokeImpl(BshMethod.java:362)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.bsh.BshMethod.invoke(BshMethod.java:258)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.bsh.BshMethod.invoke(BshMethod.java:186)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.BeanShellFacade.runCachedBlock(BeanShellFacade.java:225)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.BeanShell.runCachedBlock(BeanShell.java:423)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.BeanShellAction.invoke(BeanShellAction.java:73)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.gui.InputHandler.invokeAction(InputHandler.java:342)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.gui.InputHandler.invokeAction(InputHandler.java:307)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.gui.DefaultInputHandler.handleKey(DefaultInputHandler.java:197)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.input.AbstractInputHandler.processKeyEventKeyStrokeHandling(AbstractInputHandler.java:401)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.gui.InputHandler.processKeyEvent(InputHandler.java:151)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at org.gjt.sp.jedit.textarea.TextArea.processKeyEvent(TextArea.java:4711)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.Component.processEvent(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.Container.processEvent(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.Component.dispatchEventImpl(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.Container.dispatchEventImpl(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.Component.dispatchEvent(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.KeyboardFocusManager.redispatchEvent(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.DefaultKeyboardFocusManager.dispatchEvent(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.Component.dispatchEventImpl(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.Container.dispatchEventImpl(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.Window.dispatchEventImpl(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.Component.dispatchEvent(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.EventQueue.dispatchEvent(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
1:39:47 PM [AWT-EventQueue-0] [error] BeanShellAction:  at java.awt.EventDispatchThread.run(Unknown Source)
1:40:02 PM [AWT-EventQueue-0] [debug] EditBus: DynamicMenuChanged[menu=recent-files,source=null]
1:40:03 PM [jEdit I/O #1] [debug] WorkThread: Running in work thread: [id=14,run=org.gjt.sp.jedit.bufferio.BufferAutosaveRequest[Report1.m (C:\vehdyn_toolbox\R2011b\VehDyn.mks\CR\@vdCR\)]]
1:40:37 PM [AWT-EventQueue-0] [debug] EditBus: DockableWindowUpdate[what=ACTIVATED,dockable=log-viewer,source=org.gjt.sp.jedit.gui.DockableWindowManagerImpl[,0,0,1331x851,layout=org.gjt.sp.jedit.gui.DockableLayout,alignmentX=0.0,alignmentY=0.0,border=javax.swing.plaf.synth.SynthBorder@6d7ffbf,flags=9,maximumSize=,minimumSize=,preferredSize=]]
1:41:03 PM [AWT-EventQueue-0] [debug] EditBus: DynamicMenuChanged[menu=recent-files,source=null]


Bah, I found the problem.  The original file I'm opening is read-only and WhiteSpace plugin has "remove trailing whitespace enabled"

This results in the following error, which then trashes the edit history:

java.lang.RuntimeException: buffer read-only
at org.gjt.sp.jedit.buffer.JEditBuffer.remove(JEditBuffer.java:777)
at whitespace.DocumentUtilities.removeTrailingWhiteSpace(DocumentUtilities.java:107)
at whitespace.WhiteSpacePlugin.bufferSaving(WhiteSpacePlugin.java:154)
at whitespace.WhiteSpacePlugin.handleMessage(WhiteSpacePlugin.java:96)
at org.gjt.sp.jedit.EditBus.dispatch(EditBus.java:267)
at org.gjt.sp.jedit.EditBus.sendImpl(EditBus.java:302)
at org.gjt.sp.jedit.EditBus.access$200(EditBus.java:86)
at org.gjt.sp.jedit.EditBus$SendMessage.run(EditBus.java:482)
at org.gjt.sp.jedit.EditBus.send(EditBus.java:202)
at org.gjt.sp.jedit.Buffer.save(Buffer.java:459)
at org.gjt.sp.jedit.Buffer.save(Buffer.java:413)
at org.gjt.sp.jedit.Buffer.saveAs(Buffer.java:379)
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 org.gjt.sp.jedit.bsh.Reflect.invokeMethod(Reflect.java:134)
at org.gjt.sp.jedit.bsh.Reflect.invokeObjectMethod(Reflect.java:80)
at org.gjt.sp.jedit.bsh.Name.invokeMethod(Name.java:855)
at org.gjt.sp.jedit.bsh.BSHMethodInvocation.eval(BSHMethodInvocation.java:75)
at org.gjt.sp.jedit.bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:102)
at org.gjt.sp.jedit.bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:47)
at org.gjt.sp.jedit.bsh.BSHBlock.evalBlock(BSHBlock.java:130)
at org.gjt.sp.jedit.bsh.BSHBlock.eval(BSHBlock.java:80)
at org.gjt.sp.jedit.bsh.BshMethod.invokeImpl(BshMethod.java:362)
at org.gjt.sp.jedit.bsh.BshMethod.invoke(BshMethod.java:258)
at org.gjt.sp.jedit.bsh.BshMethod.invoke(BshMethod.java:186)
at org.gjt.sp.jedit.BeanShellFacade.runCachedBlock(BeanShellFacade.java:225)
at org.gjt.sp.jedit.BeanShell.runCachedBlock(BeanShell.java:423)
at org.gjt.sp.jedit.BeanShellAction.invoke(BeanShellAction.java:73)
at org.gjt.sp.jedit.gui.InputHandler.invokeAction(InputHandler.java:342)
at org.gjt.sp.jedit.jEdit$4.invokeAction(jEdit.java:3249)
at org.gjt.sp.jedit.jEdit$4.invokeAction(jEdit.java:3231)
at org.gjt.sp.jedit.EditAction$Wrapper.actionPerformed(EditAction.java:212)
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.AWTEventMulticaster.mouseReleased(Unknown Source)
at java.awt.AWTEventMulticaster.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)


------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
--
-----------------------------------------------
jEdit Users' List
jEdit-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jedit-users