IMHO both should be reported to the requester.
This is wrong all over. For real web application this may easy become security issue. ALL errors (from database, script, etc) should be reported to apache log, and not to page requester.
I mean if I was a page developer and I found that the PHP engine prints var_dump() to somewhere else than the resulting HTML page, I would be very disappointed. The same applies to syntax errors in scripts: the resulting page should describe the error.
This suggest that you never seen real PHP (or ASP or CGI), because this is exactly how it works. Errors going to apache log or to stderr when running standalone.
There's also technical reason for this behavior. You can't just dump your error message in the middle of HTML page. You don't know the context, so there's no way to ensure your error message is visible.
I mean this is the behaviour of all PHP interpreters I know, why should amuleweb differ?
That's exactly my point, you see.
Not to mention that there's no console to print to if amuleweb was started automagically by amule(d).
This because amuleweb is not real webservser, which typically have log file. I may add option for amuleweb to create log for this very purpose, but it looks like overkill to me. There's not many people going to develop templates IMHO, and those who do can start it from command line: "amuleweb -q" isn't very complicated command.