Problem
get_scene_dependencies uses the wrong SerializedProperty iterator pattern and keeps enterChildren true for every loop iteration.
Evidence
Editor/MCPServerMethods.Snapshot.cs:204-209 initializes enterChildren = true, then sets it back to true inside the loop.
- Nearby code in
Editor/MCPServerMethods.Snapshot.cs:130-136 sets enterChildren = false after the first iteration.
Editor/MCPServerMethods.Search.cs:204-210 uses the same correct flat-walk pattern for reference search.
Impact
The dependency walker can descend into nested compound properties repeatedly, producing dependency output that is inconsistent with sibling tools and likely noisier or duplicated for array/list/nested-struct-heavy components.
Suggested fix
Set enterChildren = false after the first Next(enterChildren) call, matching the other SerializedProperty walks.
Source report
Imported from audit report item: correctness (11) / Editor/MCPServerMethods.Snapshot.cs:208.
Problem
get_scene_dependenciesuses the wrongSerializedPropertyiterator pattern and keepsenterChildrentrue for every loop iteration.Evidence
Editor/MCPServerMethods.Snapshot.cs:204-209initializesenterChildren = true, then sets it back totrueinside the loop.Editor/MCPServerMethods.Snapshot.cs:130-136setsenterChildren = falseafter the first iteration.Editor/MCPServerMethods.Search.cs:204-210uses the same correct flat-walk pattern for reference search.Impact
The dependency walker can descend into nested compound properties repeatedly, producing dependency output that is inconsistent with sibling tools and likely noisier or duplicated for array/list/nested-struct-heavy components.
Suggested fix
Set
enterChildren = falseafter the firstNext(enterChildren)call, matching the other SerializedProperty walks.Source report
Imported from audit report item:
correctness (11)/Editor/MCPServerMethods.Snapshot.cs:208.