speckleworks / SpeckleCore

Check a brand new Speckle at: https://github.com/specklesystems
https://speckle.systems
MIT License
38 stars 17 forks source link

Deserializing SpeckleAbstracts objects with List<int> #98

Closed mishaelnuh closed 5 years ago

mishaelnuh commented 5 years ago

Step 0:

Actual Behaviour

Currently returns the object with an empty list. Behavior is due to the fact that all numbers are received as type long which results in an error when adding to a List<int>.

Affected Projects

SpeckleCore

Reproduction Steps & System Config (win, osx, web, etc.)

  1. Create class with a property of List<int>.
  2. Set the value of the property to be non-empty list.
  3. Allow SpeckleCore to serialize and send the object.
  4. Receiving the object returns an object with an empty list.

Proposed Solution (if any)

Convert the object to be added to the property/field list explicitly. Patch