fix: add error logging to applier, session polling, and job card clicks
- job_applier.mjs: stack traces on per-job and browser-level errors - session.mjs: log pending status and poll count during session refresh - linkedin.mjs: log warning when job card click fails instead of silent catch Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -125,6 +125,7 @@ async function main() {
|
||||
await handleResult(job, result, results, settings);
|
||||
} catch (e) {
|
||||
console.error(` ❌ Error: ${e.message}`);
|
||||
if (e.stack) console.error(` Stack: ${e.stack.split('\n').slice(1, 3).join(' | ').trim()}`);
|
||||
const retries = (job.retry_count || 0) + 1;
|
||||
if (retries <= maxRetries) {
|
||||
updateJobStatus(job.id, 'new', { retry_count: retries });
|
||||
@@ -140,6 +141,7 @@ async function main() {
|
||||
}
|
||||
} catch (e) {
|
||||
console.error(` ❌ Browser error for ${platform}: ${e.message}`);
|
||||
if (e.stack) console.error(` Stack: ${e.stack.split('\n').slice(1, 3).join(' | ').trim()}`);
|
||||
} finally {
|
||||
await browser?.browser?.close().catch(() => {});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user