Improve debugging

Knowing the line number where an error occurred really helps.