FAForever / downlords-faf-client

Official client for Forged Alliance Forever
https://faforever.com
MIT License
194 stars 119 forks source link

Updating stuck at 100% #3045

Closed alphahex99 closed 7 months ago

alphahex99 commented 8 months ago

When client updating automatically from 2023.10.0 to 2023.11.1 the download always gets stuck at 100% no matter how many times I restart.

Manual install by downloading release exe from here was required to fix.

Brutus5000 commented 8 months ago

Actually it is not stuck. The progress bar just jumps to 100% for no appearant reason. The download happens in the background and eventually launches the installation process. (Still a bug worth fixing, if we figure out the reason.)

jaques-sam commented 8 months ago

No, it does not start the installation process. It stays at this screen forever (12 minutes with a high speed internet line): afbeelding

BlackYps commented 8 months ago

I can confirm that normally it starts the installation process as soon as the download is finished. I'm not sure why it doesn't on your machine, but that seems to be a different bug.

Could it be that the wrong percentage is because the client is not able to retrieve the correct file size. I recall that we had this issue with other downloads inside the client. Maps for example

jaques-sam commented 8 months ago

At that time I was using a 5 GHz Wifi connection with sudden hiccups or very long latency, which can explain the matter. In any case, the percentage seems to go to 100% immediately, in all cases. I have some coding skills (mainly C++, Rust & a bit of Java & C#) so I could help if you can point me to the place in the source code ;-)

Brutus5000 commented 8 months ago

https://github.com/FAForever/downlords-faf-client/blob/develop/src/main/java/com/faforever/client/update/DownloadUpdateTask.java#L52

I assume the updateInfo.getSize() returns a wrong number or even 0