DMTF/Redfish-Service-Validator

`Links` object implemented as an array isn't marked as an error

jautor opened this issue · 2 comments

Implementation wrongly placed an array of links as the value of Links, but this was not flagged as an error:

{
   "Links": [ 
      {
          "@odata.id": "/redfish/v1/URI..."
      },
     {
         "@odata.id": "/redfish/v1/URI2"
     }]
}

I would have expected at least a type-mismatch error for Links (array vs object).

This is the same issue as #497; can we close this as a duplicate? When debugging that issue, the problem is for any sort of object or array of objects. This was my final comment:

This is not specific for ActionInfo. Any property that is defined as an array of objects will hit this issue.

I've been peeling some things apart and notice off behavior with propRealType, isCollection = prop.Type.getBaseType() found at line 418 in validateRedfish.py. Depending on the structure of the property in the live payload, it takes different code paths, which I would not expect; I would expect it to behave entirely based on schema definitions and not be affected by payloads from the service.

Yes, close as duplicate.