Skip to content

docs(bridge): warn on run_lua that console commands are queued - #6

Merged
Sycatle merged 1 commit into
mainfrom
docs/run-lua-queue
Aug 11, 2026
Merged

docs(bridge): warn on run_lua that console commands are queued#6
Sycatle merged 1 commit into
mainfrom
docs/run-lua-queue

Conversation

@Sycatle

@Sycatle Sycatle commented Aug 11, 2026

Copy link
Copy Markdown
Member

run_console_command warned that commands are queued with ~0.25 s of latency. run_lua said nothing — and run_lua is where the trap actually closes.

A snippet that calls RunConsoleCommand and then reads the cvar back in the same RunString reads the old value. The command runs after the execution ends, so the read is not a failure; it is simply early. Nothing in the output distinguishes the two, and the obvious conclusion — "the write was refused" — is wrong.

That cost a second session a wrong diagnosis today, reported to its own user before being retracted. Their words locate the gap exactly: the existing note covers run_console_commandread_convars, and does not cover run_lua doing both at once. They had read the note; it simply did not describe their case.

run_console_command also now says the read-back must be a separate call, rather than only quantifying the latency.

No test

Nothing here changes behaviour, and asserting that a description contains a given sentence is not a test — it restates the diff. Said plainly rather than dressed up: this one rests on review.

132 tests, unchanged.

run_console_command said commands are queued with ~0.25s of latency.
run_lua said nothing, and run_lua is where the trap actually closes: a
snippet that calls RunConsoleCommand and then reads the cvar back in the
same RunString reads the old value. The command runs after the execution
ends, so the read is not a failure, it is early -- and nothing in the
output tells the two apart. The obvious conclusion, "the write was
refused", is wrong.

That cost a second session a wrong diagnosis today, reported to its own
user before being retracted. Its report located the gap precisely: the
existing note covered run_console_command followed by read_convars, and
not run_lua doing both at once. The note had been read; it simply did
not describe that case.

run_console_command now also says the read-back must be a separate call
rather than only quantifying the latency.

No test: nothing here changes behaviour, and asserting that a
description contains a sentence restates the diff rather than proving
anything. This one rests on review.
@Sycatle
Sycatle merged commit 5b21ef3 into main Aug 11, 2026
0 of 2 checks passed
@Sycatle
Sycatle deleted the docs/run-lua-queue branch August 11, 2026 16:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant