Closed Landcross closed 3 years ago
Another validation issue:
Products -> 0 -> DisplaySkuAvailabilities -> 0 -> Sku -> Properties -> Packages
none is not an allowed value (type=type_error.none.not_allowed)
Another validation issue:
Products -> 6 -> DisplaySkuAvailabilities -> 0 -> Sku -> MarketProperties -> 0 -> FirstAvailableDate
none is not an allowed value (type=type_error.none.not_allowed)
Sorry for the spam :( Found two more validation errors:
Products -> 1 -> DisplaySkuAvailabilities -> 0 -> Sku -> Properties -> FulfillmentData -> WuBundleId
none is not an allowed value (type=type_error.none.not_allowed)
Products -> 1 -> DisplaySkuAvailabilities -> 0 -> Sku -> Properties -> BundledSkus
none is not an allowed value (type=type_error.none.not_allowed)
I found two more validation issues when running a search for 'Creed' in region 'Argentina':
Results -> 3 -> Products -> 0 -> Height
field required (type=value_error.missing)
Results -> 3 -> Products -> 0 -> Width
field required (type=value_error.missing)
Some more 😅
pydantic.error_wrappers.ValidationError: 1 validation error for CatalogResponse
Products -> 0 -> DisplaySkuAvailabilities -> 0 -> Availabilities -> 1 -> OrderManagementData
field required (type=value_error.missing)
pydantic.error_wrappers.ValidationError: 21 validation errors for CatalogSearchResponse
Results -> 1 -> Products -> 0 -> BackgroundColor
field required (type=value_error.missing)
Results -> 1 -> Products -> 0 -> ImageType
field required (type=value_error.missing)
Results -> 1 -> Products -> 0 -> Icon
pydantic.error_wrappers.ValidationError: 2 validation errors for CatalogResponse
Products -> 0 -> MarketProperties -> 0 -> OriginalReleaseDate
field required (type=value_error.missing)
Products -> 0 -> DisplaySkuAvailabilities -> 0 -> Sku -> MarketProperties -> 0 -> FirstAvailableDate
invalid datetime format (type=value_error.datetime)
The FirstAvailableDate is an empty string in the error-case.
Thanks for your report, testing and detailed error messages. Could you send a PR?
Simply edit the fields to be Optional[type]
but you probably know that already ;)
Sure, it should be available now in #41 . I had modified the models.py file locally already anyway. I'm not exactly too familiar with pull-requests, so I hope it all went well :)
When I search the catalog for product ID
9P29XK3N9SVQ
(Assassin’s Creed Valhalla + Watch Dogs: Legion Bundle) the following error is raised:However, when inspecting the raw api response, it seems to work fine. So, I think the validations are a little too restricted for the above values.