Skip to content

fix: Youtube Miner will interact with website to reveal more data bef… - #42

Merged
dani-beltran merged 2 commits into
mainfrom
fix-yt-miner
Jun 5, 2026
Merged

fix: Youtube Miner will interact with website to reveal more data bef…#42
dani-beltran merged 2 commits into
mainfrom
fix-yt-miner

Conversation

@dani-beltran

@dani-beltran dani-beltran commented Jun 5, 2026

Copy link
Copy Markdown
Owner

…ore scraping

Fixes: #41

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR aims to address Issue #41 (“Youtube reports are sometimes missing date”) by ensuring the YouTube page is interacted with (expanding the description area) before scraping, so the date becomes available in the scraped content.

Changes:

  • Add a pre-scrape interaction step for YouTube pages to click the “expand” control before extracting sections.
  • Upgrade @danilidonbeltran/webscrapper to 2.3.0 to support the new interaction capability.
  • Update the lockfile to reflect the dependency upgrade.

Reviewed changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated 2 comments.

File Description
src/lib/data-mining/YoutubeMiner.ts Adds a DOM interaction step (click expand) before scraping YouTube content to improve date extraction reliability.
package.json Bumps @danilidonbeltran/webscrapper to 2.3.0 to enable interaction steps.
package-lock.json Updates resolved version/integrity/metadata for the upgraded webscrapper dependency.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/lib/data-mining/YoutubeMiner.ts Outdated
browser: "chromium",
headless: true,
timeout: 30_000,
interactionSteps: [{ "event": "click", "target": "#expand", "wait": 1000 }],
Comment thread src/lib/data-mining/YoutubeMiner.ts Outdated
browser: "chromium",
headless: true,
timeout: 30_000,
interactionSteps: [{ "event": "click", "target": "#expand", "wait": 1000 }],
@codecov-commenter

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 80.58%. Comparing base (e8b0678) to head (8d48ffe).
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@           Coverage Diff           @@
##             main      #42   +/-   ##
=======================================
  Coverage   80.58%   80.58%           
=======================================
  Files          41       41           
  Lines         855      855           
  Branches      170      167    -3     
=======================================
  Hits          689      689           
  Misses        166      166           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@dani-beltran
dani-beltran merged commit dc88213 into main Jun 5, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Youtube reports are sometimes missing date

3 participants