Easier debugging is a common request. In abstraction, I imagine we all agree.
But I disagree that existing error messages are "too general to be useful". That in turn is too exaggerated to be helpful. I benefit from error messages all the time.
What is trickier here is to move towards the program being smart enough to tell you what you should have written. That is a very difficult, ultimately impossible, goal.
Longer error messages would not necessarily be more helpful. If they appeared by default they would more often be irritating than helpful. Did you know that you can click on an error code to see a longer message?
Knowing where an error occurred is indeed a key part of debugging. Did you know about set trace? A common complaint is that that produces far too much output. The common request that error messages be of the form
error on line 19 of program foo
called at line 42 of program bar
....
called at line 666 of program myprog
is, I understand, on StataCorp's long-term to do list in some form or another. I understand it's trickier than one imagines for reasons that depend on Stata's internals.
P.S. Please see FAQ Advice Section 18.
-
Login or Register
- Log in with
Leave a comment: