From 5262cbd41189262b3b2247011e989c4b789a14cc Mon Sep 17 00:00:00 2001 From: Tanner Date: Thu, 5 Nov 2026 17:44:52 +0000 Subject: [PATCH] Refine AGENTS.md --- AGENTS.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index d684ead..50ff366 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -15,6 +15,7 @@ - Run tests with `.venv/bin/python -m unittest discover -s tests -v`. - Run a syntax check with `.venv/bin/python -m compileall -q mosfet tests` and `git diff --check`. - Add regression tests for packet encodings, world-state behavior, and migrated job state transitions. +- Do not git commit changes until explicitly asked each time. - If changes span both repositories, commit bot and pyCraft changes separately. ## Theory @@ -30,7 +31,7 @@ ## Live Checks -- For one-off live checks, start `mosfet.py` inside a Python heredoc so the test can inspect `app.g` and shut the bot down cleanly. Run from the repo root, keep `SERVER=127.0.0.1`, and let `GAME_PASSWORD` come from the environment. +- For one-off live checks, start `mosfet.py` inside a Python heredoc so the test can inspect `app.g` and shut the bot down cleanly. Run from the repo root, keep `SERVER=127.0.0.1`. ```sh SERVER=127.0.0.1 PLAYER_NAME=mosfet1 .venv/bin/python - <<'PY' @@ -51,7 +52,7 @@ try: time.sleep(0.1) else: raise TimeoutError("bot did not finish joining/loading nearby chunks") - print("mosfet1 position:", tuple(g.pos)) + print(time.monotonic(), "mosfet1 position:", tuple(g.pos)) g.commands.handle_chat(("CHAT", "test", "tester: 1ping")) finally: if g.get("job") and g.get("connection") and g.connection.connected: @@ -65,3 +66,4 @@ PY - Give enough time for the bot and world to load. - Always include the `finally` cleanup. +- When printing during live checks, include `time.monotonic()` to better understand the timing of events.