From de959cb7f64f19e7f4272471e688192f5c22327c Mon Sep 17 00:00:00 2001 From: Patrick Nelson Date: Thu, 27 Aug 2015 19:38:15 -0400 Subject: [PATCH] Including stack traces when exceptions occur. --- code/MigrateTask.php | 1 + code/MigrationException.php | 20 ++++++++++---------- 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/code/MigrateTask.php b/code/MigrateTask.php index eef96fd..277f8c6 100644 --- a/code/MigrateTask.php +++ b/code/MigrateTask.php @@ -94,6 +94,7 @@ public function run($request) { DB::getConn()->transactionRollback(); $this->output("ERROR (" . $e->getCode() . "): " . $e->getMessage()); $this->output("\nNote: Any database changes have been rolled back."); + $this->output($e->getTraceAsString()); } // Revert back to previous error handling. diff --git a/code/MigrationException.php b/code/MigrationException.php index 9a848ff..cdba89b 100644 --- a/code/MigrationException.php +++ b/code/MigrationException.php @@ -1,10 +1,10 @@ -