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:
Ludovic Marie
2026-10-15 17:49:54 +02:00
parent ef8b045d79
commit ce87bfb8c7
62 changed files with 238 additions and 89 deletions
+2 -2
View File
@@ -342,7 +342,7 @@ def horizon_client_joins(vanilla_server, binary, world, build, reference):
server.wait_for(r'Done \(')
env = dict(os.environ, HORIZON_NO_AUDIO='1', HORIZON_NET_REPORT=str(report))
with (build / 'horizon-client-run.log').open('w') as log:
subprocess.run([str(c) for c in [binary, '--resources', lab.LOCAL / 'horizon-client/26.3', '--render-distance', 2,
subprocess.run([str(c) for c in [binary, '--resources', lab.RESOURCES, '--render-distance', 2,
'--server', f'127.0.0.1:{port}', '--name', PLAYER]],
cwd=client_dir, env=env, stdout=log, stderr=subprocess.STDOUT, timeout=300, check=True)
server.wait_for(r'left the game', timeout=30)
@@ -394,7 +394,7 @@ def main():
cwd=lab.ROOT, text=True))
binary = Path(metadata['target_directory']) / 'release' / ('horizon-client.exe' if os.name == 'nt' else 'horizon-client')
vanilla_server = ['java', '-Xmx2g', '-Duser.timezone=UTC', '-cp', dependencies, 'net.minecraft.server.Main', 'nogui']
horizon_server = [binary, '--resources', lab.LOCAL / 'horizon-client/26.3', '--dedicated', '--nogui']
horizon_server = [binary, '--resources', lab.RESOURCES, '--dedicated', '--nogui']
# The world, generated once by vanilla.
generate = build / 'generate'