Skip to content

chore: rescan the archive weekly instead of daily - #15

Open
yidakra wants to merge 1 commit into
mainfrom
chore/weekly-rescan
Open

yidakra wants to merge 1 commit into
mainfrom
chore/weekly-rescan

Conversation

@yidakra

@yidakra yidakra commented Sep 1, 2026

Copy link
Copy Markdown
Owner

A full rescan of this archive is a ~13-hour NFS find (measured twice: 11h48m on Aug 30, 13h on Sep 1), so the tool's 24-hour cache expiry spends roughly half of every day scanning.

This sets SCAN_CACHE_MAX_AGE_HOURS=168 in the run script (overridable via env), keeping the freshness guarantee bounded: ~40 new videos accumulate per week at observed rates (1,219 over the 31 weeks the stale cache hid them), which is a few hours of GPU work per weekly rescan.

The tool default stays at 24h — this is a deployment decision for this archive's size, expressed where the deployment lives.

No code changes; bash -n clean.

A full rescan of this archive is a ~13-hour NFS find, so the tool's 24 h
cache expiry spends half of every day scanning. Weekly keeps the freshness
guarantee bounded (~40 new videos accumulate per week at observed rates,
a few hours of GPU work) at 1/7th the scan load. Overridable via the
SCAN_CACHE_MAX_AGE_HOURS env var.
Copilot AI lite review requested due to automatic review settings September 1, 2026 20:13
@coderabbitai

coderabbitai Bot commented Sep 1, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Team

Run ID: 690ec1cd-229b-4a0a-b807-8d5827ce90f8

📥 Commits

Reviewing files that changed from the base of the PR and between 79aa6d4 and f6a897d.

📒 Files selected for processing (1)
  • scripts/run_archive_transcriber.sh

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.


📝 Walkthrough

Summary by CodeRabbit

  • Enhancements
    • Archive transcription scans now retain cached results for up to one week by default, reducing unnecessary repeat scans.
    • Cache duration can be configured for different operational needs.

Walkthrough

The archive transcriber script adds a SCAN_CACHE_MAX_AGE_HOURS setting with a 168-hour default and passes it to the tool through --scan-cache-max-age-hours.

Changes

Archive transcriber cache

Layer / File(s) Summary
Configure and pass scan cache age
scripts/run_archive_transcriber.sh
The script defines the environment-backed cache age and passes the value to the archive transcriber command.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Merge Risk: ⚪ Minimal · up to f6a89

The archive launcher will reuse scan results for up to 168 hours by default, reducing expensive rescans while allowing an environment override. The behavior is bounded and validated, and no actionable merge-blocking risk remains beyond normal checks and review.

Poem

A rabbit reads each line,
The patch grows clear beneath the moon,
Small changes hop in place,
Tests guard the garden path,
Reviews bloom before the dawn.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description check ✅ Passed The description directly explains the weekly cache configuration, the NFS scan cost, the expected operational effect, and validation performed.
Title check ✅ Passed The title clearly and concisely describes the main change: changing archive rescans from daily to weekly.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1 files.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

The change is a small, well-scoped deployment-script adjustment that uses an existing, tested CLI flag and preserves safe override behavior via environment variables.

Pull request overview

Updates the archive transcriber deployment script to reduce expensive NFS rescans by extending the scan-cache expiry window for this specific large archive, while keeping the tool’s default behavior unchanged.

Changes:

  • Introduces SCAN_CACHE_MAX_AGE_HOURS in the run script with a default of 168 hours (weekly), overridable via environment.
  • Passes --scan-cache-max-age-hours through to archive_transcriber.py to enforce the weekly cache policy at runtime.
File summaries
File Description
scripts/run_archive_transcriber.sh Sets a weekly scan-cache max age (env-overridable) and forwards it to the transcriber CLI to avoid daily full NFS rescans.
Review details
  • Files reviewed: 1/1 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

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.

2 participants