Repository navigation
Mirror remote components into the inspector's remote world - #26039
Open
jbuehler23 wants to merge 13 commits into
Open
jbuehler23 wants to merge 13 commits into
jbuehler23 wants to merge 13 commits into
Conversation
eugineerd
reviewed
Oct 6, 2026
Comment on lines
+726
to
+727
| /// shrinks collections. Other components are inserted. Relationship targets such as `Children` | ||
| /// are never written, since the hooks of their relationships build them. |
Contributor
There was a problem hiding this comment.
I haven't read through everything properly so I'm not sure if it's an issue, but something I encountered when experimenting with remote world concept is that if you insert just RelationshipSources you lose ordering present in RelationshipTargets.
Contributor
Author
There was a problem hiding this comment.
Good catch! The mirror now keeps the server's Children order and sorts the mirrored Children to match after each poll, without running any hooks. It's just Children for now since there's no generic way to reorder other relationship targets
jbuehler23
force-pushed
the
jackdaw/inspector-remote-components
branch
from
October 7, 2026 07:41
70e3a81 to
ba29bad
Compare
Co-authored-by: Daniel Skates <zeophlite@gmail.com>
jbuehler23
force-pushed
the
jackdaw/inspector-remote-components
branch
from
October 8, 2026 10:31
ba29bad to
270ba03
Compare
Co-authored-by: Daniel Skates <zeophlite@gmail.com>
jbuehler23
force-pushed
the
jackdaw/inspector-remote-components
branch
from
October 8, 2026 13:17
270ba03 to
e9e836e
Compare
This branch has not been deployed
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Stacked on #26014. Review the last commit only.
Objective
Part of #23013.
#26014 mirrors remote entities into a separate world but only inserts their names and parents, so selecting a remote entity shows almost nothing. This fills the remote world with real component values so the details panel works the same for a remote app as for the local one.
Solution
Following Zeophlite's idea of treating the remote app as just another world, every component the polls already receive is now inserted into the remote world, as long as inserting it can't do anything besides store the value.
ComponentHooks, so each type is probed once on a separate empty world, checking its required components too.ChildOfis the one exception, its hook only buildsChildrenChildrenare never inserted from JSON, since that detaches every child, they're built fromChildOfinsteadPointerIdandPointLight, show their raw JSON read-only in the details panel insteadSome bevy_ecs changes would make this simpler or more complete. A public accessor on
ComponentHookswould replace the probe. A data-only insert that skips hooks and observers, or entity ranges, would let components with hooks be inserted too. And the reserve and set-generation API mentioned in #26014 would replace the allocator workaround.A follow-up could also replace the raw JSON fallback with typed fields, by fetching the server's type schema (
registry.schema) and building dynamic reflected values from it, so types the inspector doesn't know or that have hooks still get proper widgets.AI disclosure
This builds on Zeophlite's world design from #26014. Before writing any code I had AI research what breaks when you insert arbitrary components into a bare world, which turned up the generation, allocator,
PointerIdandChildrenproblems, then implement it with a test for each and check it end to end against the server example. I reviewed the design and the changes.