Mysterious data changes

This error has cost me almost two days to debug:

Conditional Breakpoint

Its only symptoms where spurious but widespread changes to a single property. While this is “obviously” human error, these “easy” points would have mitigated the damage done:

  • strict type checking: the expression is of type string and not of type bool, the C# compiler would have known the difference and issued an error
  • in-band evaluation: The expression didn’t trigger breakpoints within the MethodName property. This would have pinpointed the cause of the data change immediately
  • constant vigilance!

2 Responses to “Mysterious data changes”

  1. Simon says:

    should that be MethodName==”ToString”
    ie == not =

  2. Exactly! It is sooo galling…

Leave a Reply