-
Notifications
You must be signed in to change notification settings - Fork 27
Closed
Description
Using "@container" : "@type" when Framing JSON-LD fails when @type is missing.
Test
Graph
{
"@context": {
"@vocab": "http://schema.org/"
},
"@type": "Event",
"location": {
"@id": "http://kg.artsdata.ca/resource/K11-200"
}
}
Frame
{
"@context": {
"@vocab": "http://schema.org/",
"location": {
"@type": "@id",
"@container": "@type"
}
},
"@type": "Event"
}
Expected behaviour
"@none" when there is no @type.
Result from JSON-LD Playground
{
"@context": {
"@vocab": "http://schema.org/",
"location": {
"@type": "@id",
"@container": "@type"
}
},
"@type": "Event",
"location": {
"@none": "http://kg.artsdata.ca/resource/K11-200"
}
}
Current behaviour
NoMethodError: undefined method `keys' for "http://kg.artsdata.ca/resource/K11-200":String
if compacted_item.keys.length == 1 && expanded_item.keys.include?('@id')
Metadata
Metadata
Assignees
Labels
No labels