[PR #3101] [MERGED] Scoreboard: report a failed write instead of dropping it #4803

Closed
opened 2026-11-03 05:08:04 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/3101
Author: @Domanffe
Created: 10/28/2026
Status: ✅ Merged
Merged: 10/29/2026
Merged by: @levzzz5154

Base: main ← Head: fix/scoreboard-write-failure


📝 Commits (2)

  • be8b86d Scoreboard: report a failed write instead of dropping it
  • c3dceac Merge remote-tracking branch 'origin/main' into upd/3101

📊 Changes

1 file changed (+9 additions, -5 deletions)

View changed files

📝 crates/horizon-client/src/game/scoreboard.rs (+9 -5)

📄 Description

🤖 Opened by Alexander's AI agent (Hermes), not by Alexander himself.

save_scoreboard wrote both data/minecraft/world_border.dat and the
scoreboard with let _ = save::write_dat(..). A full disk, a read-only world
directory or a failed rename inside write_dat therefore dropped the
objectives, scores and the world border with no trace: the next load just had
the previous file, and nothing in the log said why.

Both writes now log the failure, the shape command_storage.rs and
bossbars.rs already use:

log::warn!("the scoreboard was not written: {e}");

No behaviour changes on a successful write.

cargo clippy -p horizon-client --all-targets -- -D warnings → clean;
cargo fmt --all --check clean.

No new test: forcing write_dat to fail needs the scoreboard path to be a
directory, and the save path takes the world root from the game. The change is
the two error arms.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/3101 **Author:** [@Domanffe](https://github.com/Domanffe) **Created:** 10/28/2026 **Status:** ✅ Merged **Merged:** 10/29/2026 **Merged by:** [@levzzz5154](https://github.com/levzzz5154) **Base:** `main` ← **Head:** `fix/scoreboard-write-failure` --- ### 📝 Commits (2) - [`be8b86d`](https://github.com/horizon-rust/horizon/commit/be8b86d47068dba2d53703ce56db03c7bddc2b2c) Scoreboard: report a failed write instead of dropping it - [`c3dceac`](https://github.com/horizon-rust/horizon/commit/c3dceac2aac5b4d12e9e93f8183e1cf545982b04) Merge remote-tracking branch 'origin/main' into upd/3101 ### 📊 Changes **1 file changed** (+9 additions, -5 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/game/scoreboard.rs` (+9 -5) </details> ### 📄 Description > 🤖 Opened by Alexander's AI agent (Hermes), not by Alexander himself. `save_scoreboard` wrote both `data/minecraft/world_border.dat` and the scoreboard with `let _ = save::write_dat(..)`. A full disk, a read-only world directory or a failed rename inside `write_dat` therefore dropped the objectives, scores and the world border with no trace: the next load just had the previous file, and nothing in the log said why. Both writes now log the failure, the shape `command_storage.rs` and `bossbars.rs` already use: log::warn!("the scoreboard was not written: {e}"); No behaviour changes on a successful write. `cargo clippy -p horizon-client --all-targets -- -D warnings` → clean; `cargo fmt --all --check` clean. No new test: forcing `write_dat` to fail needs the scoreboard path to be a directory, and the save path takes the world root from the game. The change is the two error arms. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 05:08:04 +07:00
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
horizon-rust/horizon#4803
No description provided.