Closed lenaxus closed 8 months ago
Update: I invested more time to find the problem. I checked this minimal AAS and it was valid. This has brought me further in the validation.
The json of this minimal AAS is the following:
{
"assetAdministrationShells": [
{
"assetInformation": {
"assetKind": "NotApplicable",
"globalAssetId": "something_eea66fa1"
},
"id": "something_142922d6",
"modelType": "AssetAdministrationShell"
}
]
}
I have two open questions about this validation:
"submodels": []
it becomes invalid. Why is an empty array for submodels invalid?Thanks you for updating this. Concerning your points:
Hi @lenaxus, we updated the underlying JSON schema library, so that you get much more information now:
Check JSON
Does not match all sub-schemas
Reference #/$defs/Environment is invalid
Property assetAdministrationShells is invalid
item 0 is invalid
Reference #/$defs/AssetAdministrationShell is invalid
Does not match all sub-schemas
Property assetInformation is invalid
Reference #/$defs/AssetInformation is invalid
Does not match all sub-schemas
Reference #/$defs/Constraint_AASd-131 is invalid
Does not match exactly one sub-schema
Does not match all sub-schemas
Property specificAssetIds is missing
Does not match all sub-schemas
Property globalAssetId is missing
Property submodels is invalid
Array is shorter than 1
The problem is that your AAS violates constraint AASd-131: The globalAssetId or at least one specificAssetId shall be defined for AssetInformation.
@lenaxus Are you still having problems? Otherwise I would close this issue?
Expected Behavior
I want to check my AASes to prove if they are Metamodel Version 3 confirm. I have choosen the variant to check json data directly. I had troubles when checking my AASes because it said all the time they are invalid. So I started with the simplest and minimal example. I created a new empty AAS in the AASX Package Explorer and exported the JSON of it. I expected that this AAS would be valid.
Actual Behavior
Unfortunately the result of the checked AAS is that is invalid:
Steps to Reproduce the Problem
I used this script to check the AAS with the JSON directly in the python script: