Skip to content

fix: safer install records, autosave target and extension undo in formskills - #17

Merged
nodemode-ai merged 4 commits into
mainfrom
fix/review-2026-11-28
Nov 29, 2026
Merged

nodemode-ai merged 4 commits into
mainfrom
fix/review-2026-11-28

Conversation

@gbarnai

@gbarnai gbarnai commented Nov 29, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Installing a skill whose folder name matches one installed from a different app (or from your own skills) now stops and names both apps. It goes ahead only with force. A copy or release of the same app still replaces it as before, and the window's Install anyway button gets its own label for this case.
  • Install and uninstall hold an exclusive lock on installed.lock (the standard library's File::lock, no new dependency) from reading installed.json to writing it. Installs running at the same time now keep every record.
  • Autosave writes the text that was typed to the skill and file it was typed in, even when a save is still in progress or another skill is opened before the save delay ends. Opening another skill saves any pending edit first.
  • An extension's Undo for edit-start, own-new and edit-write now acts only while the result is unchanged. Any open edit is saved and compared first; if something changed, the copy or file is kept and the status line says why. edit-start registers no Undo when a copy already exists, including one made from the command line.
  • New tests in cli/tests/resilience.rs: installing_a_skill_from_another_app_under_the_same_folder_needs_force and installs_run_at_the_same_time_keep_every_record. Both fail on the previous code.
  • Test plan: cargo test --locked -p formskills-core -p formskills-cli (38 passed), npm run typecheck, npm run build, and setup/apps.py --check.

Tests

  • Each fix has a test that fails on the previous code where practical.
  • The repo CI commands were run locally on macOS. Every failure seen locally also fails on main in the same environment (missing local tools or platform-specific tests); none is introduced here.
  • Please rely on this PR's CI run for Linux and Windows.

For the owner

  • A few related items need an owner decision; they are listed separately, not here.

How to ship

  • Independent of other repos; merge in any order. No version bump; release as usual.

… install records

An install whose folder was recorded from a different app now needs force.
Install and uninstall hold a lock on installed.lock while they change
installed.json, so two installs at once keep both records.
The autosave now records which skill and file the edit belongs to, and
opening another skill saves first, so a skill opened within the save delay
no longer receives the previous skill's text.
Undoing edit-start or own-new now discards the copy only when every file
still holds what the step left, and edit-write's undo restores the old text
only while the file still holds what was written. edit-start checks the
engine for an existing copy before registering an undo.
The autosave now records the text along with the skill and file it was
typed in, so a save that waits for an earlier one, or opening a skill of
your own that clears the editor, cannot change what is written.
@gbarnai
gbarnai requested a review from nodemode-ai as a code owner November 29, 2026 18:19
@nodemode-ai
nodemode-ai merged commit aba4e22 into main Nov 29, 2026
4 checks passed
@nodemode-ai
nodemode-ai deleted the fix/review-2026-11-28 branch November 29, 2026 18:51
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.

2 participants