[GH-ISSUE #2159] An interrupted engine update leaves BUILD.json.prev and no BUILD.json; UPDATE.bat then skips the engine silently #864

Closed
opened 2026-11-04 01:46:33 +07:00 by bsakaguchi · 2 comments
Owner

Originally created by @ByteJuggler on GitHub (Oct 12, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/2159

On a Windows/NVIDIA install, UPDATE.bat kept saying Strata is updated (engine 0.1.39) although MIN_ENGINE is 0.1.43.1. No update was attempted and no reason was given.

State: engine/ had BUILD.json.prev (0.1.39) and the 0.1.39 exes, but no BUILD.json. The folder was last changed during an earlier update that was interrupted (most likely by a PC crash/reboot).

Cause: get_prebuilt(updating=True) moves BUILD.json to BUILD.json.prev before downloading. update_installed_engine puts it back only when the update fails inside the process (new is None). A crash, reboot, closed window, Ctrl+C or SystemExit (only Exception is caught) leaves it moved aside. On every later run, update_installed_engine hits if not info.exists() ...: return and silently skips the engine, so the install never updates again.

Workaround (confirmed): with the server stopped, Move-Item engine\BUILD.json.prev engine\BUILD.json, then UPDATE.bat. It then updated normally.

Example of failure, and work-around:

Image

Suggested fix: when BUILD.json is missing but BUILD.json.prev and the exe exist, restore it (and say so) before checking the version. Optionally put it back in a finally around the download as well.

Originally created by @ByteJuggler on GitHub (Oct 12, 2026). Original GitHub issue: https://github.com/Niko1221/Strata/issues/2159 On a Windows/NVIDIA install, UPDATE.bat kept saying `Strata is updated (engine 0.1.39)` although `MIN_ENGINE` is 0.1.43.1. No update was attempted and no reason was given. **State:** `engine/` had `BUILD.json.prev` (0.1.39) and the 0.1.39 exes, but no `BUILD.json`. The folder was last changed during an earlier update that was interrupted (most likely by a PC crash/reboot). **Cause:** `get_prebuilt(updating=True)` moves `BUILD.json` to `BUILD.json.prev` before downloading. `update_installed_engine` puts it back only when the update fails inside the process (`new is None`). A crash, reboot, closed window, Ctrl+C or `SystemExit` (only `Exception` is caught) leaves it moved aside. On every later run, `update_installed_engine` hits `if not info.exists() ...: return` and silently skips the engine, so the install never updates again. **Workaround (confirmed):** with the server stopped, `Move-Item engine\BUILD.json.prev engine\BUILD.json`, then UPDATE.bat. It then updated normally. Example of failure, and work-around: <img width="843" height="793" alt="Image" src="https://github.com/user-attachments/assets/80671fed-1f08-445a-9e8a-31d2945f0d6b" /> **Suggested fix:** when `BUILD.json` is missing but `BUILD.json.prev` and the exe exist, restore it (and say so) before checking the version. Optionally put it back in a `finally` around the download as well.
Author
Owner

@qiuzan2001 commented on GitHub (Oct 15, 2026):

Reproduced on Linux with main 296b59d2 (0.1.44.1): an engine/ folder holding the exe and BUILD.json.prev but no BUILD.json makes setup.update_installed_engine return at its first check (if not info.exists() ...: return) with no message and no download, so the install stays on the old engine for good. Open PR #2161's tools/test_setup_stale_stamp.py fails against main's setup.py and passes on that branch (test_setup_choices and test_setup_amd also pass there).

<!-- gh-comment-id:6184538845 --> @qiuzan2001 commented on GitHub (Oct 15, 2026): Reproduced on Linux with main 296b59d2 (0.1.44.1): an `engine/` folder holding the exe and `BUILD.json.prev` but no `BUILD.json` makes `setup.update_installed_engine` return at its first check (`if not info.exists() ...: return`) with no message and no download, so the install stays on the old engine for good. Open PR #2161's `tools/test_setup_stale_stamp.py` fails against main's `setup.py` and passes on that branch (`test_setup_choices` and `test_setup_amd` also pass there).
Author
Owner

@Niko1221 commented on GitHub (Oct 19, 2026):

Thanks for taking the time to report this.

We're resetting the tracker for 0.2.0-beta. There are more than 1,300 open issues and pull requests, too many for us to read properly, so we're closing everything that isn't being worked on right now. Closed here does not mean rejected.

To reopen it takes about two minutes:

  1. Re-test on 0.2.0-beta. It may already be fixed. Write down what you see.
  2. Start the title with its area: [Engine], [GUI], [TUI], [Benchmark], [Docs] or [Other].
  3. Fill in the parts of the issue form: what happened, the Strata version, your graphics card, memory and system.
  4. Comment /reopen. A check runs and either reopens the issue or lists what is still missing.

The rules are in CONTRIBUTING.md.

<!-- gh-comment-id:6270848846 --> @Niko1221 commented on GitHub (Oct 19, 2026): Thanks for taking the time to report this. We're resetting the tracker for 0.2.0-beta. There are more than 1,300 open issues and pull requests, too many for us to read properly, so we're closing everything that isn't being worked on right now. Closed here does not mean rejected. To reopen it takes about two minutes: 1. Re-test on 0.2.0-beta. It may already be fixed. Write down what you see. 2. Start the title with its area: [Engine], [GUI], [TUI], [Benchmark], [Docs] or [Other]. 3. Fill in the parts of the issue form: what happened, the Strata version, your graphics card, memory and system. 4. Comment `/reopen`. A check runs and either reopens the issue or lists what is still missing. The rules are in [CONTRIBUTING.md](https://github.com/Niko1221/Strata/blob/main/CONTRIBUTING.md).
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#864
No description provided.