1
Step 4 Text Gone
Tirsvad edited this page 2026-11-20 14:32:59 +01:00

English · Dansk · Bahasa Malaysia

Step 4: Text gone

The text is gone

When more than 5 seconds pass without typing, the server deletes the text. The next state answer says was_cleared, the editor is emptied and the page shows Your text is gone. Start typing again. Typing again starts a new session.

What was gained

  • An exact rule. "More than 5 seconds" means exactly 5.0 keeps the text and 5.001 deletes it; both are tests.
  • A port for time. Clock is a Protocol in the application layer and SystemClock (monotonic time) implements it, so time can be faked.
  • A race guard. The script ignores a poll answer that started before the latest key press and does not poll while a send is unanswered, so freshly typed text is never erased by an old answer.
  • End to end in a container. These screenshots were taken with a headless browser in Docker, so the desktop was not used.