Homer 79a6f26c2f Open on the Feed, and refresh it without hammering yt-dlp
The tab order was Watch, Search, Feed, Browse, Downloads, and the app opened
on Watch -- which is where the other tabs send you, not somewhere you start.
It is now Feed, Search, Browse, Downloads, Watch, with icons. Routing is
unaffected: _tab_index_of resolves by widget identity, not position.

Refresh-on-open needed care rather than a call in showEvent. A local refresh
is one yt-dlp subprocess per subscribed channel, serially, so it is braked
four ways: only channels not seen for feed.auto_refresh_on_open_minutes (30,
0 to disable), at most eight per visit, once per interval per session, and
after a delay so it does not race the tab transition or first-run setup. The
cached feed is already on screen throughout. That is a new config key rather
than the dead auto_refresh_minutes, because existing configs store that as 0
and would have read as opting out of a feature that did not exist yet.

SmoothTabWidget gained the currentChanged signal, icons and a corner slot it
never had. Its set_current_index needed a re-entrancy flag, not just an index
check: setting the tab bar's index emits its currentChanged straight back into
the same method, and at that point the stack has not moved, so every switch
fired the activation hook twice.

The grid was cleared and rebuilt after every channel finished -- flicker, lost
scroll position and every thumbnail re-read from disk each time. merge_entries
keeps existing cards. While there, _relayout was re-adding cards the layout
already owned, so layout items accumulated on every Load more, and the resize
check compared against columnCount(), which never shrinks, so it relaid out on
every resize event.

Smaller things this exposed: feed errors were written into the label the next
success overwrote, so failures were invisible; switching to account mode left
the local videos on screen; cancel() had no callers, so a refresh outlived the
tab and the window; Browse's Subscribe never said Unsubscribe though it
toggles; "Play all" queued one page while claiming otherwise; and the feed
sorted publish times against wall-clock fetch times in one COALESCE, so the
last-refreshed channel floated to the top.

Feed is the first thing seen now, so an empty one says what to do about it
instead of showing a bare grid.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-09 01:11:40 +02:00

SageTube

A watch-first YouTube client for the desktop. Search, browse channels and playlists, follow subscriptions, and stream videos in an embedded mpv player — with the full yt-dlp download feature set inherited from YTSage.

Features

Watching

  • 📺 Embedded mpv player (Wayland/X11/Windows/macOS) with quality selector, speed, volume, subtitles, fullscreen
  • 🔍 In-app YouTube search with thumbnail card grid
  • 📂 Channel browsing (Videos / Shorts / Live) and playlist views
  • 🔔 Local subscriptions — no Google account needed — with an aggregated feed; optional real account feed via browser cookies
  • ⏯️ Watch history with resume positions and a persistent play queue
  • ⬇️ One click from any video card into the downloader

Downloading (from YTSage)

  • Format table, audio extraction, subtitles, SponsorBlock, chapters, playlists, trimming, speed limits, proxies, cookies, custom yt-dlp commands, download history — see the upstream README

Install

pip install .
sagetube

Requires libmpv for playback (Arch: pacman -S mpv) — see Building. Without it the app works as a downloader.

Fork notes

SageTube is a fork of YTSage by oop7 (MIT). The internal package keeps the ytsage name so upstream fixes remain mergeable — see Tracking upstream. The fork also fixes a number of upstream bugs (unsafe partial-file cleanup, unverified binary updates, thread-safety issues, PATH corruption on Windows — see the git log).

License

MIT — see LICENSE.

S
Description
No description provided
Readme MIT 12 MiB
5.5.2 Latest
2026-08-08 23:38:07 +00:00
Languages
Python 94.2%
Inno Setup 5.8%