Comment 3 for bug 1855771

Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/10661
Committed: https://git.mahara.org/mahara/mahara/commit/9b35263dde89fb94b74b11806ae028dd2d83ff45
Submitter: Cecilia Vela Gurovic (<email address hidden>)
Branch: master

commit 9b35263dde89fb94b74b11806ae028dd2d83ff45
Author: Robert Lyon <email address hidden>
Date: Tue Dec 10 09:12:34 2019 +1300

Bug 1855771: Allow generic system errors to give more detail

So that we can debug things easier

The Exception class has two useful methods, getFile() and getLine()
so we can use these to dispaly where the problem is rather than just
a generic: exception(object(ParseError)) at Unknown:0

To test:
- a syntax mistake - add a log_debug() line before the first function in a class
and see if the error shows the correct file/line
- MaharaException - add the following line somewher ein the code
throw new MaharaException("Missing bananas");
and see if the error shows the correct file/line

behatnotneeded

Change-Id: I5a254f842ab6444ebb324e11e2c93d1c44e3e1d3
Signed-off-by: Robert Lyon <email address hidden>