From 1383d9997a6d9bae77190cdc6f10b6e96bf11b70 Mon Sep 17 00:00:00 2001 From: sladro Date: Fri, 19 Sep 2025 16:32:07 +0800 Subject: [PATCH] fix: normalize assembly level calculation across all API endpoints MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Resolve inconsistency where api/status/model reported one fewer assembly level compared to hierarchy analysis and shell analysis APIs. Modified SafeCalculateAssemblyLevels to include root assembly in level count. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- CreoManager.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CreoManager.cpp b/CreoManager.cpp index 60e5e08..b7bda22 100644 --- a/CreoManager.cpp +++ b/CreoManager.cpp @@ -489,7 +489,8 @@ int CreoManager::SafeCalculateAssemblyLevels(wfcWAssembly_ptr assembly) { } } - return max_level; + // Add 1 to include root assembly level, consistent with hierarchy analysis + return max_level + 1; } catch (...) {