Sadly, there is no script-fu debugger, and debugging SF can be a bit tricky.
No line numbers!
Fortunately, there is a script-fu console...