YTSage icon indicating copy to clipboard operation
YTSage copied to clipboard

Bug: UI fails to refresh if "Keep Thumbnail" is checked *before* clicking Analyse

Open vsnk-ning opened this issue 2 months ago • 2 comments

📝 Description The GUI fails to populate its download-options list if the "Keep Thumbnail" option is checked before the user clicks the "Analyse" button.

Affected feature: Video URL analysis.

Bug: If "Keep Thumbnail" is checked first, clicking "Analyse" results in an empty list. The app then enters a corrupted state.

Error: Any subsequent action (like clicking download, or trying to re-analyse) can lead to the secondary crash: AttributeError: 'YTSageApp' object has no attribute 'path_input'.

This bug is 100% reproducible and is dependent on the order of operations.

Image

🔗 Affected Video URL This bug is not URL-specific. It happens with any valid YouTube URL. Example: https://www.youtube.com/watch?v=9bZkp7q19f0

🔄 Steps to Reproduce Launch YTSage.

Check the "Keep Thumbnail" box.

Paste any YouTube URL.

Click the "Analyse" button.

Bug occurs: The UI list does not refresh and remains empty.

The application is now in a broken state. Trying to analyse again or clicking "Download" (if a button is visible from a previous, unrelated session) will eventually trigger the AttributeError.

✅ Expected Behavior The UI list should correctly populate with download options, regardless of whether "Keep Thumbnail" was checked before or after the "Analyse" click.

❌ Actual Behavior The UI list remains empty, and the app's UI state becomes corrupted, leading to subsequent AttributeError crashes.

🖥️ Environment YTSage Version: 4.9.2 (from YTSage-v4.9.2-ffmpeg-Setup.exe)

Python Version:

OS: Windows 11

yt-dlp Version: 2025.11.12

FFmpeg Version: 7.1.1-full_build-www.gyan.dev

Installation Method: executable (exe)

📸 Screenshots/Logs The secondary error message is:

AttributeError: 'YTSageApp' object has no attribute 'path_input' 🛠️ Possible Fix The bug appears to be a conflict or race condition in the "Analyse" function's logic. It seems the code path for "Get Video Streams" conflicts with "Get Thumbnail" if they are triggered simultaneously, but not if they are triggered sequentially (Analyse first, Download w/ thumbnail later).

📌 Additional Context This bug is reproducible even after a clean install (deleting the app folder and C:\Users[Username].ytsage folder).

CRUCIAL WORKAROUND: The bug is completely avoided if the user follows this sequence:

Leave "Keep Thumbnail" UNCHECKED.

Paste URL and click "Analyse". (UI now loads correctly).

NOW, check "Keep Thumbnail".

Click "Download".

This works perfectly: both the video and the thumbnail are downloaded.

This confirms the bug is purely in the Analyse step's timing logic.

Checklist

[ ] I have searched existing issues to avoid duplicates

[x] I have provided the affected YouTube URL (and explained it's generic)

[x] I have included clear steps to reproduce (This is the key!)

[x] I have attached relevant screenshots/logs (the error message)

[x] I have provided all required environment details

/label ~bug ~needs-triage

vsnk-ning avatar Nov 14 '25 11:11 vsnk-ning

Yeah, this issue has actually been fixed in the beta version of the app. You can use it right now in the beta branch by running it from the source and report if it works or not, or wait a couple of days until I release the beta version 4.9.5b

oop7 avatar Nov 14 '25 12:11 oop7

Update: I have released version4.9.6b, which includes the improvement for thumbnails. You can download it here

Please let me know if this resolves the issue!

oop7 avatar Nov 29 '25 13:11 oop7

Closing this issue as fixed in version 4.9.6b. Please feel free to reopen if the problem persists!

oop7 avatar Dec 09 '25 15:12 oop7