Repository navigation
Resolve hosted roof support and refuse ambiguous conversion identities - #1110
Merged
Merged
Conversation
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.
A hosted
create_roofcall failed because roof elevation read the browser scene store through the spatial-grid singleton. Resolve wall support and wall tops from the supplied scene graph so the same operation works on the server and in the editor, including raised slabs and support offsets.A conversion that reused source identifiers across floors could overwrite its candidate nodes and fail with a missing-parent patch. Reject duplicate wall, item, opening and generated mapping keys before any compilation or scene change, with the conflicting ID in the refusal.
Validation: 71 focused core conversion/roof tests and the MCP author_scene/construction suites passed; the core, geometry-script and MCP packages rebuilt. Regression cases cover an unavailable browser store, repeated storey IDs and collisions with generated source mappings. The by-hand alternative remains normal roof placement and scene-tree editing.
Note
Medium Risk
Roof placement logic changed paths from spatial-grid to graph-based wall tops (behavior should match but affects construction); author_scene now hard-fails duplicate ids that might have partially applied before.
Overview
Roof elevation no longer goes through the browser spatial-grid / scene store when computing wall tops.
resolveRoofWallTopElevationnow derives level ancestry, slab support, and wall height from the passed-innodesgraph (wallSupportForNodes,getWallTop), so hosted MCPcreate_roofworks on saved scenes withoutuseScene.author_scenerejects duplicate source keys up front—wall and item ids across all levels, opening keys (wallId/i), and generated ids likelevel/n,room/n/i,light/n/i—withduplicate_source_idand no scene mutation. Tool copy for wallidnow states global uniqueness.Regression tests cover an unavailable browser store, repeated storey wall ids, and item ids that collide with other items or generated mappings.
Reviewed by Cursor Bugbot for commit 14a6c74. Bugbot is set up for automated code reviews on this repo. Configure here.