PHP exception not being caught, laravel, lumen
问题 When attempting to catch/handle an exception thrown from PDFParser, I cannot catch it. I use a simple try catch statement, outlined below. try{ $pdf = $parser->parseFile($filepath); $text = $pdf->getText(); } catch( \Exception $e){ $text = $paper->abstract; } The exception is thrown as follows. if (empty($data)) { throw new \Exception('Object list not found. Possible secured file.'); } The output is here. lumen.ERROR: Exception: Object list not found. Possible secured file. in /Users