[PR #6602] [MERGED] Recipe book parity cases: empty batches, forgotten highlights, every book's settings #6973

Closed
opened 2026-11-03 06:30:30 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/6602
Author: @MSedgeMC
Created: 11/1/2026
Status: ✅ Merged
Merged: 11/2/2026
Merged by: @ludovic111

Base: main ← Head: fix/recipe-book-cases


📝 Commits (1)

  • b506983 Recipe book parity cases: empty batches, forgotten highlights, every book's settings

📊 Changes

1 file changed (+10 additions, -0 deletions)

View changed files

📝 tools/test_recipe_book_parity.py (+10 -0)

📄 Description

Vanilla's ServerRecipeBook takes an empty batch as a no-op, ignores the second removeHighlight of a recipe that is no longer highlighted, drops the ids the recipe manager does not know when it loads a saved book, and keeps each of the four book types' open and filtering settings through a save and a load, in the order the settings packets arrived.

Horizon matches vanilla on all of these; the harness's random batches never built an empty give/take, a highlight removed twice, or all four book types' settings in one case, so those states were unpinned - this adds the three cases.

Proven: on the build VM, cd ~/.wt/rec1 && python3 tools/parity.py recipe_book → PASS recipe_book, 1 passed 0 failed, with the three new cases in the run.

Not proven: anything about a book saved by a version that wrote a different recipes list shape; the loader is only exercised with the compound this same oracle wrote, plus the unknown ids load already appends.


🔄 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/6602 **Author:** [@MSedgeMC](https://github.com/MSedgeMC) **Created:** 11/1/2026 **Status:** ✅ Merged **Merged:** 11/2/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/recipe-book-cases` --- ### 📝 Commits (1) - [`b506983`](https://github.com/horizon-rust/horizon/commit/b506983946a18c4deaa4d1d9dd01bfb51ec7946d) Recipe book parity cases: empty batches, forgotten highlights, every book's settings ### 📊 Changes **1 file changed** (+10 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `tools/test_recipe_book_parity.py` (+10 -0) </details> ### 📄 Description Vanilla's `ServerRecipeBook` takes an empty batch as a no-op, ignores the second `removeHighlight` of a recipe that is no longer highlighted, drops the ids the recipe manager does not know when it loads a saved book, and keeps each of the four book types' open and filtering settings through a save and a load, in the order the settings packets arrived. Horizon matches vanilla on all of these; the harness's random batches never built an empty `give`/`take`, a highlight removed twice, or all four book types' settings in one case, so those states were unpinned - this adds the three cases. **Proven:** on the build VM, `cd ~/.wt/rec1 && python3 tools/parity.py recipe_book` → `PASS recipe_book`, 1 passed 0 failed, with the three new cases in the run. **Not proven:** anything about a book saved by a version that wrote a different `recipes` list shape; the loader is only exercised with the compound this same oracle wrote, plus the unknown ids `load` already appends. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 06:30:30 +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#6973
No description provided.