My first signed-in user imported 68 channels and 23 came up empty
Plainfeed shows new videos from the YouTube channels you choose, in the order they were posted, without algorithmic recommendations or Shorts. New videos come from YouTube's free RSS feeds, and only when RSS fails does it fetch them through the YouTube API instead.
In my last post, I made channels seen for the first time fall back to the API when RSS returns 404 across the board. At the end I wrote that the number of fallbacks per request (6 at the time) and the one-hour mark would stay as they were. I raised the number to 15 on November 7, but this post is about how that limit and the one-hour mark together stopped my first signed-in outside user.
- Fallback: fetching a channel's upload list through the API when its RSS fails (1 unit per channel, out of 10,000 a day)
- Limit: how many channels one request can fall back for. I raised it from 6 to 15 when I moved to the paid plan on November 7
- One-hour mark: put on a channel seen for the first time that couldn't be fetched, so it isn't asked about again for an hour
What happened
It was the afternoon of November 10, the day I posted an introduction to Plainfeed in an online community. At 16:29 (Korea time), the first outside user signed in with Google and imported 68 YouTube subscriptions at once.
At that moment YouTube's RSS was returning 404 again. Most of the 68 were channels the server had never seen, so they needed the fallback, but each request could only fall back for 15. The 23 channels over that limit got the one-hour mark.
For an hour after a channel gets the mark, the server won't fetch it even if the app asks again. The user didn't come back during that hour, so 23 channels were most likely sitting empty on their screen. When I checked RSS again at 18:00, it was all back to 200.

Why they were blocked
In short: the one-hour mark meant to stop made-up channels also landed on real channels that just didn't fit in the limit.
The one-hour mark exists to stop requests full of made-up channel IDs from burning quota. Channels that don't exist always return 404 on RSS too, so without the mark they'd be asked about on every request.
But the code handled "a channel that exists but didn't fit in the limit" and "a channel that doesn't exist" with the same mark. And when known channels had already used up the limit, it marked new ones without even checking whether they existed. In the last post I fixed a rule that only looked after channels the server already knew. This time it was missing people who import a lot at once.
The fix
In short: channels that exist are retried on the next request with no mark, and the one-hour mark is only for channels that don't exist or that failed.
Even after the limit is used up, a channel seen for the first time whose RSS failed is checked with channels.list first. Up to 50 channels cost 1 unit. If YouTube returns the channel but the limit is full, nothing is marked. When the page is open, the app checks for new videos every 10 minutes, and the channel is fetched then.
// Shortened code (lib/youtube.js)
// for each first-time channel whose RSS failed
for (const r of unchecked) {
// doesn't exist: one-hour mark
if (!found.has(r.id)) { r.dead = true; continue; }
// exists but the limit is full: no mark, next request
if (fallbacks >= maxFallback) continue;
fallbacks++;
// fallback, 1 unit
try { r.feed = await fetchUploads(r.id); }
// fallback failed: one-hour mark
catch { r.dead = true; }
}
| RSS failed, channel seen for the first time | Before | Now |
|---|---|---|
| Exists, within the limit | Fetched via fallback | Fetched via fallback |
| Exists, over the limit | One-hour mark | No mark, retried on the next request (10 minutes later) |
| Doesn't exist | One-hour mark | One-hour mark (unchanged) |
| Existence check failed | One-hour mark | One-hour mark (unchanged) |
| Fallback failed | One-hour mark | One-hour mark (unchanged) |
There's a cost. Because it checks existence even when the limit is full, an RSS outage can cost 1 extra unit per request. The daily fallback cap (1,500 channels overall) is unchanged, so quota doesn't leak. I added the new behavior to the tests that run against fake YouTube responses.
Numbers
| Item | Value |
|---|---|
| Subscriptions imported | 68 |
| The user's channels that got the one-hour mark | 23 (of 46 marked at the time) |
| Time of the import | 16:29 |
| RSS confirmed back to normal | 18:00 |
| Fix shipped | 18:11 |
The user came back the next afternoon and added one more channel. As of November 15, all 235 channels across accounts are fetched, and new-video notifications are active for all of them.
Wrapping up
When I built the safeguard, I only pictured the requests I wanted to stop. The one it actually caught was a first-time user. There's no telling whether someone who sees empty channels on their first visit will come back. So from now on, when I write a rule to block suspicious requests, I'll also write down which normal users could get caught by the same rule.