Skip to content

[Fix] Custom skill edits disappear when an earlier save completes - #3651

Open
roomote-roomote[bot] wants to merge 1 commit into
developfrom
fix/custom-skill-pending-edits-0skzokh2jrws0
Open

roomote-roomote[bot] wants to merge 1 commit into
developfrom
fix/custom-skill-pending-edits-0skzokh2jrws0

Conversation

@roomote-roomote

@roomote-roomote roomote-roomote Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

​Opened on behalf of @daniel-lxs. Follow up by mentioning @roomote-roomote, in the web UI, or in Telegram.

Related issue

Internal product recovery work; no separate issue.

Why this PR exists

  • A maintainer explicitly invited this PR in the linked issue or discussion
  • I am a maintainer / this is internal Roomote work

What changed

Add Custom Skill accepted Description and Content edits after Save began. A successful response then closed and reset the dialog, discarding those later edits while persisting only the submitted values. Disable those two fields while saving, matching the existing Slug, availability and edit-skill form behavior. On failure the retained draft becomes editable again for correction and retry.

Two existing isSaving guards; no new state, API, dependency or visible control. Shared and environment-specific creation use the same pending state. Normal pre-save editing and successful creation remain unchanged.

How it was tested

  • Current develop fb5e231d: actual authenticated mobile dialog, real create mutation held at a disposable PostgreSQL lock. Description and Content accepted later typing; release produced success/reset and persisted only the original text. New pending assertions fail in three cases before the production edit.
  • Exact pushed head 28acf054f5f7abc94e4e87399e1799909bf965be: same real lock/create/keyboard stimulus rejects later text, then persists submitted values after release. Desktop 1440×1000 and mobile 390×844 interactions verified; committed patch is byte-identical to the visually inspected snapshot.
  • Failure/retry: abort the actual create transport, retain enabled fields/draft, remove abort, correct Content and use Save; genuine database row contains corrected text. This is local controlled-failure proof, not a live outage. All routes and locks released.
  • 27 InstanceSkills/CustomSkills client tests pass, including shared/environment pending, duplicate Save prevention and retained draft/corrected retry. Web fast types, whitespace and normal commit/pre-push gates pass: oxlint, residual ESLint, all fast package types and Knip. Full local test suite not run.
  • Three final images opened and visually inspected, with independent image review. They establish dialog layout and pending/recovered appearance; native interactions and database reads establish behavior. The existing disabled Saving button has low contrast; its styling is unchanged. No real-device keyboard, screen-reader, dark-theme or live provider claim. Environment-specific submission is covered by focused tests; screenshots show shared creation.
  • Exact-head hosted CI passes (including Test/app build/CodeQL), automated review is clean with zero findings/threads, and the PR is mergeable and ready for human review. Five synthetic proof rows were removed; no locks or routes remain.

Screenshots

Real local app, synthetic form data. Pending duration uses a disposable database lock; recovery follows a disclosed aborted create request. The recovery image was taken after the toast expired and does not show the failure itself.

Desktop pending skill creation with consistently disabled fields

Mobile pending skill creation with fields and actions contained

Mobile editable retained draft after transport failure

Related PRs

  • #3652: independent contextual automation/settings Edit names from this task.
  • #3655: independent on-demand custom MCP connection tests from this task.

Checklist

  • The PR title follows the repo convention: [Fix], [Feat], [Improve], [Refactor], [Docs], or [Chore] followed by a user-facing description
  • This PR is small and scoped to one change
  • pnpm lint and pnpm check-types pass locally — normal broad fast equivalents and actual hooks passed
  • I added tests or included a clear manual validation note above
  • I removed secrets, tokens, private keys, and customer data from code, logs, and screenshots
  • If this change should appear in the changelog, I ran pnpm changeset — small form consistency fix; no changeset

@roomote-community

roomote-community Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

No code issues found. See session

Reviewed the pending-state guards, shared/environment creation, retained drafts and corrected retries, and regression tests. Current-head lint, type checks, and Knip passed; tests, app build, and JavaScript/TypeScript CodeQL were still running when checked.

Reviewed 28acf05

This branch has not been deployed

No deployments
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