crowd.dev
crowd.dev copied to clipboard
Optimize DevTo integration to prevent excessive reparsing
Changes proposed ✍️
What
🤖 Generated by Copilot at 499360d
This pull request enhances the devto integration by optimizing the processArticleStream function to filter out stale or cached articles and avoid unnecessary processing. It also fixes a type error in the ctx.publishData function call.
🤖 Generated by Copilot at 499360d
To process a stream of articles We added some checks and particles We skip the old ones And cache the new ones And fix the type error in
publishData
Why
How
🤖 Generated by Copilot at 499360d
- Modify
getDevToArticlefunction to return cache status of article (link) - Add logic to
processArticleStreamfunction to skip processing articles with old comments and valid cache, unless onboarding (link) - Update
processArticleStreamfunction to pass only article data toctx.publishDatafunction (link)
Checklist ✅
- [ ] Label appropriately with
Feature,Improvement, orBug. - [ ] Add screehshots to the PR description for relevant FE changes
- [ ] New backend functionality has been unit-tested.
- [ ] API documentation has been updated (if necessary) (see docs on API documentation).
- [ ] Quality standards are met.