Skip to content

history: what the person did is whatever the host says the person did - #60

Merged
foxnne merged 3 commits into
mainfrom
history/person-is-the-hosts
Oct 19, 2026
Merged

foxnne merged 3 commits into
mainfrom
history/person-is-the-hosts

Conversation

@foxnne

@foxnne foxnne commented Oct 19, 2026

Copy link
Copy Markdown
Contributor

Stacked on #59; merge after it, which retargets this to main. Part of fizzyedit/plans#14.

What changes

Pixi tells an agent what the person did to a sprite since its last command (History.person, pixi#46). It counted an edit, undo or redo as the person's when none of pixi's own commands was running (commands.running == 0).

That stopped being true when fizzy's fizzy.undo .{ .path } (fizzyedit/fizzy#487) began reaching pixi through historyGoTo: that is fizzy's command, not pixi's. So an agent undoing its own draw was told, with its next command's answer, "the person changed this sprite since your last command on it".

Both places now ask the host who is acting (Host.author().kind == .person): the person at the keys, an agent's call, a tape. commands.running stays for what it is still for: telling the person's activity with the running command's answer.

Verified

Live on macOS (the sandbox from #59): an MCP client drew, undid with fizzy.undo .{ .path }, drew, and undid four times more.

  • Before: each answer after an undo carried .person = .{ .note = "the person changed this sprite…", .undone = 1 }, four in all.
  • After: none.

The person's own undo by key was not driven live, since a tape's key is its tape's author, not the person's. It is the host's input author that marks it as the person's.

zig build (sandbox, --fork), zig fmt --check.

🤖 Generated with Claude Code

foxnne and others added 2 commits October 18, 2026 20:21
An edit after going back used to drop everything gone back over. Now the
steps gone back over return to the line, then their reverses, then the
edit: the sprite is where it was gone back to, and every step is still on
the line. The reverses read "Back to <step>" and are credited to whoever
went back. Kinds that don't swap the same way both directions (resize,
deleted layers and animations, merges, cell reorders, grid changes) still
drop what was gone back over, as before.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Pixi counted an edit or an undo as the person's when none of pixi's own
commands was running, so an agent's `fizzy.undo` (fizzy's command, not
pixi's) came back to it as "the person changed this sprite". It now asks
the host who is acting (`Host.author`).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@foxnne
foxnne changed the base branch from history/going-back-is-a-step to main October 19, 2026 04:00
main holds #59 squashed; this branch keeps its own reading of who acts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@foxnne
foxnne merged commit a24a234 into main Oct 19, 2026
5 of 6 checks passed
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