set process.exitCode = 1 on error; don't want to rethrow
This commit is contained in:
parent
1b319cacf7
commit
704c4b01e1
3 changed files with 4 additions and 1 deletions
|
|
@ -162,7 +162,8 @@ try {
|
|||
// await page.screenshot({ path: p, fullPage: true });
|
||||
await page.locator(games_sel).screenshot({ path: p });
|
||||
} catch (error) {
|
||||
console.error('Catch error:', error); // .toString()?
|
||||
console.error(error); // .toString()?
|
||||
process.exitCode = 1;
|
||||
if (error.message && !error.message.includes('Target closed')) // e.g. when killed by Ctrl-C
|
||||
notify(`prime-gaming failed: ${error.message.split('\n')[0]}`);
|
||||
} finally {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue