mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-20 15:18:08 +02:00
Merge pull request #19148 from nicolo-ribaudo/error-preserve-trace
Do not stringify errors when logging them
This commit is contained in:
commit
c198e0b446
12 changed files with 21 additions and 20 deletions
|
@ -86,7 +86,7 @@ async function downloadManifestFiles(manifest) {
|
|||
try {
|
||||
await downloadFile(file, url);
|
||||
} catch (ex) {
|
||||
console.error(`Error during downloading of ${url}: ${ex}`);
|
||||
console.error(`Error during downloading of ${url}:`, ex);
|
||||
fs.writeFileSync(file, ""); // making it empty file
|
||||
fs.writeFileSync(`${file}.error`, ex);
|
||||
}
|
||||
|
|
|
@ -1192,7 +1192,7 @@ class Driver {
|
|||
resolve();
|
||||
})
|
||||
.catch(reason => {
|
||||
console.warn(`Driver._send failed (${url}): ${reason}`);
|
||||
console.warn(`Driver._send failed (${url}):`, reason);
|
||||
|
||||
this.inFlightRequests--;
|
||||
resolve();
|
||||
|
|
|
@ -18,7 +18,7 @@ const TestReporter = function (browser) {
|
|||
resolve();
|
||||
})
|
||||
.catch(reason => {
|
||||
console.warn(`TestReporter - send failed (${action}): ${reason}`);
|
||||
console.warn(`TestReporter - send failed (${action}):`, reason);
|
||||
resolve();
|
||||
|
||||
send(action, json);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue