Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 15 additions & 4 deletions src/socials/scrapeAndPollSocials.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,17 +59,28 @@ export async function scrapeAndPollSocials(
continue;
}

if (!scrapeResult.runId || !scrapeResult.datasetId) {
logger.warn("Scrape returned null runId or datasetId", {
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DRY - @recoup-coding-agent update to use the shared logging lib

artistId: social.artistId,
socialId: social.socialId,
username: social.username,
runId: scrapeResult.runId,
datasetId: scrapeResult.datasetId,
});
continue;
}

batchRuns.push({
runId: scrapeResult.runId!,
datasetId: scrapeResult.datasetId!,
runId: scrapeResult.runId,
datasetId: scrapeResult.datasetId,
});

startedScrapes.push({
artistId: social.artistId,
socialId: social.socialId,
username: social.username,
runId: scrapeResult.runId!,
datasetId: scrapeResult.datasetId!,
runId: scrapeResult.runId,
datasetId: scrapeResult.datasetId,
});
}

Expand Down