yt-briefing 0.3.1 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -24,6 +24,7 @@ out = JSON.parse(`bun run src/yt-sweep.ts --reset`) // Bash — first call: --
24
24
  while true:
25
25
  out.status:
26
26
  "done" → sweep finished — tell the user, stop
27
+ "error" → setup/config problem (e.g. missing API key) — show `out.error` to the user verbatim, stop
27
28
  "rate_limited" → transcript fetch blocked (usually a blocked egress IP) — tell the user, stop; recovery in README.md → Proxy
28
29
  "rating_needed" → steps A–E
29
30
  ```
package/dist/yt-sweep.js CHANGED
@@ -542,5 +542,12 @@ if (reset) {
542
542
  clearRest();
543
543
  clearPrefetch();
544
544
  }
545
+ // Fatal config check, foreground only (the detached --fill / --prefetch children already
546
+ // exited above). A missing YouTube Data API key makes EVERY channel expansion throw the same
547
+ // error, which the per-channel `catch` collapses to 0 items — surfacing as a misleading
548
+ // `status:"done"` ("no new videos"). Fail fast with a clear, actionable error instead.
549
+ if (!process.env.YT_BRIEFING_YOUTUBE_API_KEY) {
550
+ emit({ status: 'error', error: 'YT_BRIEFING_YOUTUBE_API_KEY is not set — add a YouTube Data API v3 key to .yt-briefing/.env (see README → first run / .env.example).' });
551
+ }
545
552
  const queue = loadQueue() ?? buildQueue();
546
553
  await advance(queue);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "yt-briefing",
3
- "version": "0.3.1",
3
+ "version": "0.3.2",
4
4
  "description": "A self-learning YouTube briefing engine: it sweeps the channels you follow, filters noise in two stages (title, then transcript), summarizes the rest in your language, and adapts to your ratings — one video at a time.",
5
5
  "type": "module",
6
6
  "bin": {