Repository navigation
Finish Connection, control and UI owner operations #1908
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
72ac5cd
Plan finish Connection, control and UI owner operations
eric8810 2b46b5d
Merge remote-tracking branch 'origin/main' into impl-1908-connections
eric8810 786cf00
Serve UI connection cleanup and extension registration on their owners
eric8810 491ea92
Merge remote-tracking branch 'origin/main' into impl-1908-connections
eric8810 2bab82a
Keep native daemon and connection handles private to the server
eric8810 25e6610
Match UiHost TypeScript results to the synchronous dispatcher
eric8810 d3ac98c
Verify connection presence when a disposed UI leaf finishes
eric8810 d53aefc
Admit UI manifests at the shared registration entry before preparing …
eric8810 f7a68b0
Use the SDK bridge value type for UI manifests
eric8810 919bb70
Merge remote-tracking branch 'origin/main' into impl-1908-connections
eric8810 de3b7a7
Align the UI fixture, generated bindings and manifest ownership docs
eric8810 52d7ec3
Resolve UI registration paths from the installed plugin ID
eric8810 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Problem: package_by_id returns any installed entry or default directory without checking the selected and enabled state. using() is the state check: it returns None for an off name and the chosen candidate otherwise (crates/dim-app-server/src/plugin_manager.rs:577-605). This lookup never calls it. UiExtensions::register publishes whatever it returns (crates/dim-app-server/src/ui_extensions/mod.rs:140-180), so the face accepts a plugin the user turned off.
Failure scenario: install plugin X (install selects it: crates/dim-app-server/src/plugin_manager.rs:1246, 1342-1349) and let PluginManager register its UI. Disable X, or install a second copy Y and select it; PluginManager withdraws X's UI (crates/dim-app-server/src/plugin_manager.rs:2060-2065, 441-445; docs/design/client-ui-extensions.md:77). A trusted row that injects uiExtensions, as runtime/fixtures/ui-owner.ts:8,35-38 does, calls uiExtensions.register({plugin:'X', manifest:{version:1, root:'ui', panels:[...]}}). package_by_id still returns X's install directory, prepare copies the root, and ui.extensions.list and ui.extensions.read serve a plugin that is off or replaced. A default plugin name has the same problem after the name switches to an installed copy, because defaults.plugins.get(id) ignores the choice. This contradicts client-ui-extensions.md:69 and client-ui-extensions.md:433.
Evidence: crates/dim-app-server/src/plugin_manager.rs:191-200, 577-605, 1246, 1342-1349, 2060-2065; crates/dim-app-server/src/ui_extensions/mod.rs:140-180; runtime/fixtures/ui-owner.ts:8,35-38; docs/design/client-ui-extensions.md:69,77,433; docs/design/contracts/process-owner-operations.md:30.
Fix: require the id to be the candidate using() returns for its name (Use::Installed(id) for an installed entry, Use::Default for a default). Normal callers already pass that id (crates/dim-app-server/src/plugin_manager.rs:416-433, 2071-2096), and the Node test still passes because install defaults enable=true and records use_ (crates/dim-app-server/src/plugin_manager.rs:1246, 1342-1349). Add a test that registers a disabled id and expects Unknown plugin ID with no catalog entry. If any trusted caller may republish disabled content is intended, update client-ui-extensions.md:69, 77 and 433 and add that test.