Description
Issue identified by @nofcfy-fanqi in #389 :
GhJSON validation error occurs when creating or editing scripts. If neither Id nor InstanceGuid are provided to GhJSON.Core, it produces an error: "Component must have either 'id' or 'instanceGuid'". The ID assignment logic is still new and might require additional testing; in future releases, either a correct Id will be provided or GhJSON.Core will be modified to automatically set it.
Operating System
macOS
Rhino Version
RH8.28
SmartHopper Version
1.4.0-alpha
Steps to Reproduce
- Generate or edit a script using SmartHopper
- GhJSONComponent is created with InstanceGuid = null and Id is not set
- Attempt to validate or save the GhJSON
- Observe debug error indicating missing Id or InstanceGuid.
Expected Behavior
Script Generation should provide the correct ID, or GhJSON.Core should automatically assign a valid Id if none is provided.
Additional Material
No response