diff --git a/scrape-blog.ts b/scrape-blog.ts index 2707a2f..0a98dca 100644 --- a/scrape-blog.ts +++ b/scrape-blog.ts @@ -90,10 +90,11 @@ async function fetchBlogPosts(): Promise { } }; - // Process posts with limited concurrency - const results = await Promise.allSettled( - postUrls.slice(0, 10).map(processPost) // Limit to 10 posts for initial testing - ); + // Process posts sequentially with delay + const results = []; + for (const url of postUrls.slice(0, 10)) { // Limit to 10 posts for initial testing + results.push(await processPost(url)); + } const posts: BlogPost[] = results .filter((result): result is PromiseFulfilledResult =>