Tools read the pinned Minecraft version from research-lock.json
lab.VERSION, lab.GAME (.local/minecraft/<version>) and lab.RESOURCES (.local/horizon-client/<version>) come from the lock, and lab.version_info() reads the pinned client jar's version.json. Every harness, generator and tool that named 26.3 (resource folders, jar and source paths, result records, the vanilla client's --version and asset index, the bare login client's protocol, the benchmark's options.txt data version, the packet id table's header) uses them, so a candidate worktree pinned to another version runs them unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -10,6 +10,11 @@ import argparse
|
||||
import json
|
||||
from pathlib import Path
|
||||
|
||||
try:
|
||||
from . import lab
|
||||
except ImportError:
|
||||
import lab
|
||||
|
||||
ROOT = Path(__file__).resolve().parents[1]
|
||||
STATES = ["handshake", "status", "login", "configuration", "play"]
|
||||
DIRECTIONS = ["clientbound", "serverbound"]
|
||||
@@ -25,8 +30,9 @@ def main():
|
||||
parser.add_argument("--out", type=Path, default=ROOT / "crates/horizon-protocol/src/ids.rs")
|
||||
args = parser.parse_args()
|
||||
report = json.loads(args.report.read_text())
|
||||
info = lab.version_info()
|
||||
lines = [
|
||||
"//! Packet ids per connection state and direction for protocol 777 (26.3).",
|
||||
f"//! Packet ids per connection state and direction for protocol {info['protocol_version']} ({info['name']}).",
|
||||
"//! Generated by tools/generate_packet_ids.py from the data generator's",
|
||||
"//! packets report; do not edit by hand.",
|
||||
"#![allow(missing_docs)]",
|
||||
|
||||
Reference in New Issue
Block a user