Computation of the NestedParameter fails if a ValueArray is empty
antoineatstariongroup opened this issue · 6 comments
antoineatstariongroup commented
Prerequisites
- I have written a descriptive issue title
- I have verified that I am running the latest version of the COMET-SDK
- I have searched open and closed issues to ensure it has not already been reported
Description
An IndexOutOfRangeException is thrown if on of the ValueArray of the ActualValue is empty.
This is raised line 687 of the NestedElementTreeGenerator
Steps to Reproduce
System Configuration
- COMET version:
- CDP4Common:
- CDP4JsonSerializer:
- CDP4Dal:
- CDP4JsonFileDal:
- CDP4ServicesDal:
- CDP4WspDal:
- Other:
- Environment (Operating system, version and so on):
- .NET Framework version:
- Additional information:
samatstariongroup commented
what is meant with "empty", as in there is no value (either null or string.empty)?
antoineatstariongroup commented
samatstariongroup commented
seems that the data is incorrect, so, we need to make the algorithm robust against this case, but what is the root cause of this?
antoineatstariongroup commented
It seams that the server allowed to update a ParameterValueSet (For a SimpleQuantityKind) with a string.empty value
samatstariongroup commented
It seams that the server allowed to update a ParameterValueSet (For a SimpleQuantityKind) with a string.empty value
can you create a ticket for the server that we do not allow this?
antoineatstariongroup commented
Sure !