[PR #5653] [MERGED] CI: daily check for a republished Mojang version JSON #6418

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

📋 Pull Request Information

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

Base: main ← Head: fix-3333-mojang-republish


📝 Commits (2)

  • 4647ce7 CI: daily check for a republished Mojang version JSON (#3333)
  • 598fcb7 Mojang republish check: hourly, not daily (rdbtCVS: a day of broken prepares is too long)

📊 Changes

3 files changed (+228 additions, -0 deletions)

View changed files

➕ .github/workflows/mojang-republish.yml (+31 -0)
➕ tests/test_mojang_republish.py (+76 -0)
➕ tools/ci/mojang_republish.py (+121 -0)

📄 Description

🤖 Opened by Joansitoh's AI agent (Claude Code, Sonnet 5.5), not by Joansitoh personally.

What

Proposal A of #3333: a daily workflow (.github/workflows/mojang-republish.yml, also workflow_dispatch with dry_run) runs tools/ci/mojang_republish.py. It reads Mojang's public version manifest and takes the pinned version's entry. If its sha1 is manifest_sha1 or in accepted_manifest_sha1 (the rule of tools/lab.py manifest_accepted, with a test that both agree), it prints one line and stops. Otherwise it downloads that version JSON and compares the client and server jar sha1s and the Java major with the lock, then opens an issue Mojang republished 26.3: <sha8> with the new manifest and assetIndex sha1s, a ready-to-paste snippet for accepted_manifest_sha1 / accepted_asset_index_sha1, and "Jars unchanged" or "JARS CHANGED: do not accept".

Why

A republished version JSON currently surfaces only when a player's horizon-prepare fails on it. This catches it the day Mojang publishes.

Notes

  • The lock has no library hashes, so libraries cannot be verified from it. The issue and docstring say so; "jars unchanged" covers the two jars and the Java major only.
  • Dedupe is by exact title prefix over open and closed issues (no label needed). A known issue is not commented on again, so it adds no daily noise.
  • Only hashes go in issues; no Mojang file is stored.
  • Run against the live manifest today (read-only): 26.3: Mojang's version JSON is known to the lock, nothing to do.
  • Proposal B (horizon-prepare) is left to the maintainers.

Fixes #3333

pr_ready

pr_ready (tools/pr_ready.py --base upstream/main, against upstream/main at 14262d059)

Check Result
Scope ✅ 3 files, +228 −0
Cargo.lock ✅ unchanged
Public tree ✅
Python tests ✅ 518 passed
Rust checks ➖ no Rust change
Parity ✅ 1 affected, all passed
Label skip-release

🤖 Generated with Claude Code


🔄 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/5653 **Author:** [@Joansitoh](https://github.com/Joansitoh) **Created:** 11/1/2026 **Status:** ✅ Merged **Merged:** 11/1/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix-3333-mojang-republish` --- ### 📝 Commits (2) - [`4647ce7`](https://github.com/horizon-rust/horizon/commit/4647ce7af7ba5d72d5827db40c2ae0be1e2af500) CI: daily check for a republished Mojang version JSON (#3333) - [`598fcb7`](https://github.com/horizon-rust/horizon/commit/598fcb7b862defb45344fdbdbc70213d80e4cc80) Mojang republish check: hourly, not daily (rdbtCVS: a day of broken prepares is too long) ### 📊 Changes **3 files changed** (+228 additions, -0 deletions) <details> <summary>View changed files</summary> ➕ `.github/workflows/mojang-republish.yml` (+31 -0) ➕ `tests/test_mojang_republish.py` (+76 -0) ➕ `tools/ci/mojang_republish.py` (+121 -0) </details> ### 📄 Description > 🤖 Opened by Joansitoh's AI agent (Claude Code, Sonnet 5.5), not by Joansitoh personally. ## What Proposal A of #3333: a daily workflow (`.github/workflows/mojang-republish.yml`, also `workflow_dispatch` with `dry_run`) runs `tools/ci/mojang_republish.py`. It reads Mojang's public version manifest and takes the pinned version's entry. If its sha1 is `manifest_sha1` or in `accepted_manifest_sha1` (the rule of `tools/lab.py manifest_accepted`, with a test that both agree), it prints one line and stops. Otherwise it downloads that version JSON and compares the client and server jar sha1s and the Java major with the lock, then opens an issue `Mojang republished 26.3: <sha8>` with the new manifest and assetIndex sha1s, a ready-to-paste snippet for `accepted_manifest_sha1` / `accepted_asset_index_sha1`, and "Jars unchanged" or "JARS CHANGED: do not accept". ## Why A republished version JSON currently surfaces only when a player's `horizon-prepare` fails on it. This catches it the day Mojang publishes. ## Notes - The lock has no library hashes, so libraries cannot be verified from it. The issue and docstring say so; "jars unchanged" covers the two jars and the Java major only. - Dedupe is by exact title prefix over open and closed issues (no label needed). A known issue is not commented on again, so it adds no daily noise. - Only hashes go in issues; no Mojang file is stored. - Run against the live manifest today (read-only): `26.3: Mojang's version JSON is known to the lock, nothing to do.` - Proposal B (`horizon-prepare`) is left to the maintainers. Fixes #3333 ## pr_ready **pr_ready** (`tools/pr_ready.py --base upstream/main`, against upstream/main at 14262d059) | Check | Result | | --- | --- | | Scope | ✅ 3 files, +228 −0 | | Cargo.lock | ✅ unchanged | | Public tree | ✅ | | Python tests | ✅ 518 passed | | Rust checks | ➖ no Rust change | | Parity | ✅ 1 affected, all passed | | Label | `skip-release` | 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 06:20:16 +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#6418
No description provided.