Re #10674 Better formatted diagnostics

(does it have anything to do with failing unit test?)
Merge branch 'bugfix/10674_hardmaskOpt' into develop