Report filename of file that generated an error
-
It would be great to have RRF output the file name of the file or macro that caused an error message. Here's a recent example:
M32 "0:/gcodes/Dimension/1002_face.gcode" File 0:/gcodes/Dimension/1002_face.gcode selected for printing Error: line 19 column 26: meta command: reached null object before end of selector string Cancelled printing file 0:/gcodes/Dimension/1002_face.gcode, print time was 0h 0m
Line 19 in the
1002_face.gcode
file is aG94
command so that clearly didn't trigger the error. The print file itself doesn't even contain any meta gcode itself, but it calls macros that do. It would be incredibly helpful for debugging and diagnosis purposes to output the macro name or filename that the error occurred in.Right now, if you're calling macros from a print file that then call other macros, it can be incredibly tricky to track down where the error actually is. In my experience, the line number doesn't necessarily match up with the actual (editable) file location either, since this looks like it is affected by comments and blank lines.
-
@NineMile its already a feature request https://github.com/Duet3D/RepRapFirmware/issues/761