Issue Description
When deleting a SmartObject property and renaming another property in the same SmartObject to the name of the deleted property, an error occurs when creating a package which includes the SmartObject.

Error Message
A property with the same name and namespace already exists in the model. name = 'Guid' and namespace 'urn:SourceCode/SmartForms/View?CustomerInfo-IV#Sources.88c48b3c-424b-4574-8327-8502af984a0e/Fields.Service Location.


Cause
The deleted property caused duplicate fields in the XML.

Repro Steps

  1. Create a SmartObject.
  2. Create an associated SmartObject.
  3. Create a view from the first SmartObject.
  4. Delete the Drop-Down control.
  5. Add a new Drop- Down control.
  6. Configure the data source to load the associated SmartObject.
  7. Then bind the control to the associated field.
  8. Edit the associated SmartObject.
  9. Add a property named Property2.
  10. Finish the SmartObject.
  11. Edit the view and finish.
  12. Edit the associated SmartObject.
  13. Add a property named Property3.
  14. Finish the SmartObject.
  15. Edit the associated SmartObject.
  16. Delete Property2.
  17. Modify Property3’s name to Property2.
  18. Edit the view and finish.
  19. Create a package, an error occurs.

Resolution

  1. Ensure you have K2 4.7 installed.
  2. Install the K2 4.7 February 2017 Cumulative Update.
  3. Get the K2 4.7 February 2017 Cumulative Update FP2 from Regional Support.
  4. Install the K2 4.7 February 2017 Cumulative Update FP2 to apply the fix.