Skip to content

Allow editing of previously recorded results - #152

Merged
istathar merged 15 commits into
technique-lang:mainfrom
istathar:edit
Sep 8, 2026
Merged

istathar merged 15 commits into
technique-lang:mainfrom
istathar:edit

Conversation

@istathar

@istathar istathar commented Sep 8, 2026

Copy link
Copy Markdown
Member

We have had the problem that if the user inadvertently presses <Enter> one too many times they will record a result that was unintended and incorrect. Further, as a learning matter, if someone has entered a value and then realizes it needs amending, there was no way to edit it.

This branch introduces the Revoke state to the PFFTT format which invalidates a previously recorded result, allowing the trail to be re-run from that point and values downstream of it re-prompted for. This also updates the PFFTT file format to include a serial for each scope. Together with the path address it now uniquely identifies an iteration of an invocation (whereas the path alone does not).

Pressing <Up> at a live prompt now enteres a "navigation" mode where the user can step back through what the run has already recorded. At a position that already had a result recorded, <Esc> opens menu and offers Edit to change the value

The behaviour of this "navigation" is somewhat complex, so a .moves file is added to the test suite to show what the expected location is after different keystroke permutations from each position.

Internally, keystroke procesing and dispatch have been refactored into two separate layers. The first maps a KeyEvents to an Intents. The second handles those Intent depending on the context.

@istathar istathar self-assigned this Sep 8, 2026
@istathar

istathar commented Sep 8, 2026

Copy link
Copy Markdown
Member Author

@istathar
istathar merged commit 0eba7e1 into technique-lang:main Sep 8, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant