Refactors error readout in console - now prints exception stack using console.error