-
-
Notifications
You must be signed in to change notification settings - Fork 21.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rework and simplify update checking logic #92597
Rework and simplify update checking logic #92597
Conversation
125a894
to
32386d7
Compare
32386d7
to
44593ee
Compare
Tested the windows artifact, now it doesn't show anything so... It's working? |
If nothing appears it means there is no new version available. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks good, I'll try to do some tests to make sure it works for different build names.
Did some quick testing by adding 4.3-beta2, 4.3-stable, and 4.4-dev1 to |
Thanks! |
Fixes #92593
I have rewritten the update checking logic based on the new format from godotengine/godot-website#858. Unfortunately there was a nasty bug in the previous version that will make users not get notified about beta2 .-.
releases
array is no longer iterated; instead only the first (newest) release is checked.UpdateStatus::DEV
, which was effectively unused and made logic more complex.[]
toget()
, so it's safer now (it didn't crash, but it's better to be safe).Some more testing appreciated. For testing different versions faster, you can replace the code that loads JSON with a custom one that loads a local file:
String s = FileAccess::get_file_as_string("somewhere/versions.json");
.