BKSalman / ytdlp-gui

a GUI for ytdlp written in Rust
GNU General Public License v3.0
222 stars 10 forks source link

Blank white screen on Windows 10 #22

Closed WebDev222 closed 4 months ago

WebDev222 commented 9 months ago

Hello! After opening the ytdlp-gui.exe file, an empty window opens for a few seconds and closes. Nothing else happens. I tried both as administrator and without. What can this problem be related to?

изображение

BKSalman commented 9 months ago

Привет! :) (literally the only useful word I know lol)

first of all, could you run the application from powershell like this ytdlp-gui.exe --version? if you are on the latest version it will print out the version and hopefully the git hash, which would make debugging easier.

also try running it from powershell with the YTG_LOG environment variable set like this:

$env:YTG_LOG=debug

ytdlp-gui.exe

and check if there is anything suspicious going on there probably red ERROR lines or something, and share it here

I'm not totally sure if that works because I haven't used powershell that much

Note: please don't run random applications as administrator unless you know what they do exactly.

WebDev222 commented 9 months ago

When running the ytdlp-gui.exe --version command through PowerShell, nothing happens изображение

When the command

$env:YTG_LOG=debug 
ytdlp-gui.exe 

is executed, the white ytdlp-gui.exe window opens and closes only for a few seconds. PowerShell says that "the name "debug" is not recognized as the name of a cmdlet, function, script file or executable" изображение

BKSalman commented 9 months ago

When running the ytdlp-gui.exe --version command through PowerShell, nothing happens

this probably means you're not running the latest version 1.0.0, so to start, you can download that from the releases page

is executed, the white ytdlp-gui.exe window opens and closes only for a few seconds. PowerShell says that "the name "debug" is not recognized as the name of a cmdlet, function, script file or executable"

ah that's probably my mistake, I think you need to add quotes like this:

$env:YTG_LOG="debug"

then just run the application as normal

ytdlp-gui.exe
WebDev222 commented 9 months ago

I didn't have any other versions, but just in case I downloaded the "ytdlp-gui-windows-64.zip" version again from the releases page. The result is almost the same:

изображение

BKSalman commented 9 months ago

this is very strange, I honestly don't know why this is not working, however you can check the log files in something like C:\Users\Alice\AppData\Local\ytdlp-gui\logs (not sure since I don't use windows now)

if you find it, and see something there that could be useful, please share it.

BKSalman commented 9 months ago

if all fails, you could try to build the program from source and move it from <clone-repository-root-folder>\target\release\ytdlp-gui to the C:\Users\ds\Documents\Soft\ytdlp-gui-windows-64 folder (because you need ffmpeg and yt-dlp to be in the same place since I didn't package it properly for windows), and see if the blank screen issue is solved

WebDev222 commented 9 months ago

These are the logs I found at C:\Users\Alice\AppData\Local\ytdlp-gui\logs logs.zip

BKSalman commented 9 months ago

2023-10-02T06:11:42.445240Z ERROR wgpu_hal::auxil::dxgi::result: Command allocator creation failed: 0x887A0005

this is probably some graphics/rendering error, I have no idea how to solve it tbh, but if you want to try compiling the project from source it might help

WebDev222 commented 9 months ago

I compiled the program following these instructions, but the executables at <project-root>/target/debug/ytdlp-gui and <project-root>/target/release/ytdlp-gui do not have the extension .exe. If you add the .exe extension manually, the program does not start, the following message appears: "Unable to run this application on your PC. To find a version for your computer, please contact the publisher of the application".

explorer_ccyTR3ihh0

Note: perhaps this is due to the fact that I compiled in Linux?

BKSalman commented 9 months ago

Indeed if you compile the binary on linux it's by default gonna compile it as an ELF (the executable format linux uses), and it also doesn't have an extension like windows .exe, you can either cross compile it on linux for windows, or just compile it on windows

WebDev222 commented 9 months ago

Unfortunately, no reliable information about cross-compiling could be found. Could you please tell me how to implement it? Should I use mingw-w64?

BKSalman commented 9 months ago

This stackoverflow answer here has enough information I think

https://stackoverflow.com/a/62853319

tldr:

I kinda doubt that compiling it yourself would make any difference, but I hope it works

I think the main problem is with graphics and stuff, if the machine you're running the application on is old or very low end, that might be the issue, not that the application is heavy, but graphical drivers support and whatever (I'm not too knowledgeable about graphics)

BKSalman commented 9 months ago

ACTUALLY, you could try enabling the iced glow renderer by using this patch:

diff --git a/Cargo.toml b/Cargo.toml
index dc23203..2ea965e 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -19,7 +19,7 @@ members = [
 [dependencies]
 chrono = { version = "0.4.23", default-features = false, features = ["clock"] }
 dirs = "4.0.0"
-iced = { version = "0.9.0" }
+iced = { version = "0.9.0", features = ["glow"] }
 iced_aw = { version = "0.5.0", features = ["tabs", "modal", "card"], default-features = false }
 iced_native = "0.10.0"
 native-dialog = "0.6.3"

to apply the patch you can create a file in the repository, and put the text above inside of it, then run git apply the-name-of-the-file.

then recompile it.

sorry for the inconvenience since I don't really use windows, but we can try fixing it :)

if that doesn't work, maybe when I update iced (the GUI library used for this project) it could work, because it has a software renderer that probably supports more older hardware and stuff

BKSalman commented 7 months ago

Any update on this issue?

I understand if it was too much to ask you to do all of these things

BKSalman commented 4 months ago

since there was no reply I'm going to close this issue, if you still want help with this issue you are welcome to reopen it