You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 14, 2023. It is now read-only.
I've been using the Azure Table Storage CLI that is built on top of the Python SDK. One of the issues I noticed that in some cases that when I query an entity I get an EntityProperty as a property value and in other cases I do not. From what I can gather I get an EntityProperty in the cases where the value cannot be inferred (through isinstance checks).
This is a bit inconvenient as I cannot just write a switch and compare entity.property.type to the EDM types that are available with table storage, I have to check whether the property value is an EntityProperty, if it is then I have to check its EDM type, if it isn't an EntityProperty then I need to do checks on the actual value. This has side-effects in the Azure CLI tools as well, see azure-cli/8033 OData Type is Not Always Specified When Querying Entities for more details.
The code bellow creates a test table, inserts an entity will all possible property types and retrieves it. If the property value is an EntityProperty then the type is displayed from property_value.type otherwise it is displayed from type(property_value).
I would like that all property values to be consistent, i.e.: for all of them to be EntityProperty instances or at least have a flag to retrieve them as such.
The text was updated successfully, but these errors were encountered:
I've been using the Azure Table Storage CLI that is built on top of the Python SDK. One of the issues I noticed that in some cases that when I query an entity I get an EntityProperty as a property value and in other cases I do not. From what I can gather I get an EntityProperty in the cases where the value cannot be inferred (through
isinstance
checks).This is a bit inconvenient as I cannot just write a switch and compare
entity.property.type
to the EDM types that are available with table storage, I have to check whether the property value is anEntityProperty
, if it is then I have to check its EDM type, if it isn't anEntityProperty
then I need to do checks on the actual value. This has side-effects in the Azure CLI tools as well, see azure-cli/8033 OData Type is Not Always Specified When Querying Entities for more details.The code bellow creates a test table, inserts an entity will all possible property types and retrieves it. If the property value is an
EntityProperty
then the type is displayed fromproperty_value.type
otherwise it is displayed fromtype(property_value)
.I would like that all property values to be consistent, i.e.: for all of them to be
EntityProperty
instances or at least have a flag to retrieve them as such.The text was updated successfully, but these errors were encountered: