Skip to content

fix: recover from incompatible user plugins on startup - #82

Open
KuthorX wants to merge 1 commit into
dataelement:mainfrom
KuthorX:codex/auto-disable-incompatible-plugins
Open

fix: recover from incompatible user plugins on startup#82
KuthorX wants to merge 1 commit into
dataelement:mainfrom
KuthorX:codex/auto-disable-incompatible-plugins

Conversation

@KuthorX

@KuthorX KuthorX commented Aug 18, 2026

Copy link
Copy Markdown

Summary

  • expand Harness AggregateError logging so nested loader-entry failures remain visible
  • detect verified host/plugin API incompatibilities only for packages installed in the user web profile
  • disable incompatible entries in the real user cordis.patch.yml and sync .dsh-market/state.json
  • retry startup once, then show a native Desktop notice listing the disabled plugins
  • require the Harness entry-loaded marker as well as HTTP readiness to avoid transient startup races

Root cause verified

  • dsh-inline-images: service "inlineImages" has been registered
  • focus / dsh-plugin-focus: unsupported JSON schema: schema.required is not supported by the value schema DSL
  • both failures were hidden behind the top-level AggregateError: loader entries failed to apply

User-visible behavior

  • Desktop automatically disables the incompatible plugins and recovers startup
  • Plugin Market shows both switches off and reports patch disabled
  • Desktop displays a native notice naming the plugins and asks the user to update them before re-enabling

Safety

  • built-in plugins are excluded by requiring a matching package manifest under $DSH_HOME/profiles/web/node_modules
  • only the two verified compatibility failure classes trigger recovery
  • ordinary startup failures such as missing user configuration are not auto-disabled
  • patch text is appended without parsing/stringifying, preserving comments and !!js expressions
  • market groups/order are preserved; invalid market state is never overwritten
  • recovery retries at most once

Verification

  • npm run typecheck
  • npm run build
  • npm test (16 files, 85 tests)
  • subprocess integration covers a transient HTTP-ready state followed by plugin load failure
  • packaged macOS build tested against the real profile with both plugins enabled:
    • first attempt reports both verified incompatibilities
    • Desktop writes disabled: true for loader ids and both package names to market state
    • second attempt reaches DSH entry loaded without a recovery patch argument
    • native recovery notice lists both plugins
    • Plugin Market shows dsh-inline-images and dsh-plugin-focus disabled with switches off

@KuthorX
KuthorX force-pushed the codex/auto-disable-incompatible-plugins branch from 7478888 to 24e3263 Compare August 18, 2026 10:29
@KuthorX KuthorX changed the title Recover from incompatible user plugins on startup fix: recover from incompatible user plugins on startup Aug 18, 2026
@KuthorX
KuthorX force-pushed the codex/auto-disable-incompatible-plugins branch from 24e3263 to ef22c5e Compare August 18, 2026 11:09
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