tamaki.mes.backup.compare.getKeyFields
Description
Returns the list of key field names that uniquely identify entities of the given entityType, looked
up from the package's entityTypesToKeyFields constant. For example, locations is keyed by
["path"] and operations by ["name", "locationPath"].
Raises a TypeError if entityType is not a string, or a ValueError if it is not a recognised
entity type.
Syntax
tamaki.mes.backup.compare.getKeyFields(entityType)
Parameters
| Parameter | Type | Nullable | Description |
|---|---|---|---|
entityType | String | False | The entity type (for example locations, materials). |
Returns
A List of String field names that uniquely identify entities of that type.
Code Examples
print(tamaki.mes.backup.compare.getKeyFields("operations"))
# ['name', 'locationPath']