Author Topic: [v1.8.3.6] Log hangs on null with "Do not show unrecognized items" enabled  (Read 1586 times)

Pfeil

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4782
  • RTFM
While the "Do not show unrecognized items" option is enabled, attempting to write null to the log will cause it to break.

E.G.
Code: [Select]
public class VAInline
{
public void main()
{
VA.WriteToLog(null);
VA.WriteToLog("test");
}
}
will cause nothing to be written to the log ("test" never appears, no blank entries either, it just remains in its previous state), and prevents the log from being updated from that point forward.

Selecting and copying text does still work, as does "Edit this command" where relevant.

Attempting to use the "Clear" option (if there are items in the log to clear, otherwise this option is grayed out) from the context menu results in this exception (and the log is not actually cleared):
Quote
System.NullReferenceException: Object reference not set to an instance of an object.
   at Telerik.WinControls.UI.BaseListViewVisualItem.OnPropertyChanged(RadPropertyChangedEventArgs e)
   at Telerik.WinControls.RadObject.RaisePropertyNotifications(RadPropertyValue propVal, Object oldValue, Object newValue, ValueSource oldSource)
   at Telerik.WinControls.RadObject.SetValueCore(RadPropertyValue propVal, Object propModifier, Object newValue, ValueSource source)
   at Telerik.WinControls.RadElement.SetValueCore(RadPropertyValue propVal, Object propModifier, Object newValue, ValueSource source)
   at Telerik.WinControls.ComponentInputBehavior.HandleHoveredElementsChanged(List`1 newHoveredElements)
   at Telerik.WinControls.ComponentInputBehavior.SelectElementOnMouseOver(MouseEventArgs e)
   at Telerik.WinControls.ComponentInputBehavior.OnMouseMove(MouseEventArgs e)
   at Telerik.WinControls.RadControl.OnMouseMove(MouseEventArgs e)
   at Telerik.WinControls.UI.RadListView.OnMouseMove(MouseEventArgs e)
   at System.Windows.Forms.Control.WmMouseMove(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at Telerik.WinControls.RadControl.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
which will keep re-appearing even after clicking "Continue", rendering VoiceAttack mostly unusable until it is closed and restarted.

The same exception is thrown when enabling the "Show latest entries only" option, if there are entries to clear (presumably for the same reason "Clear" does).


Enabling the "Do not show unrecognized items" option after null has already been written to the log will not cause any apparent issues.


A practical example of something that would cause this is
Code: [Select]
public class VAInline
{
public void main()
{
VA.WriteToLog(VA.GetText("variableThatDoesNotExist"));
}
}


This issue actually existed pre-Telerik in v1.7.8, however there it only causes the log to stop updating; Clearing keeps working, and no exception is thrown.


EDIT: Fixed in v1.8.3.7
« Last Edit: January 21, 2020, 08:02:39 PM by Pfeil »

Gary

  • Administrator
  • Hero Member
  • *****
  • Posts: 2832
I think I've got this issue wrangled.  Thank you for the very detailed description of what was going on.