Unable to filter out null objects if referenced by encoding
See original GitHub issue{
"$schema": "https://vega.github.io/schema/vega-lite/v2.json",
"description": "Unable to truly filter data",
"data": {
"values":[
{
"date": "2000-01-01"
},
{
"date": "2000-02-01",
"options": {
"price": 16
}
},
{
"date": "2000-03-01",
"options": {
"price": 17
}
}
]
},
"transform": [{"filter": "datum.options != null"}],
"mark": "line",
"encoding": {
"x": {"field": "date", "type": "temporal", "axis": {"format": "%Y"}},
"y": {"field": "options.price", "type": "quantitative"}
}
}
This will throw “ERROR TypeError: Cannot read property ‘price’ of undefined” in the console. I’m not sure why “options.price” would ever try to be evaluated for the record which was supposed to be filtered out.
Issue Analytics
- State:
- Created 6 years ago
- Comments:11 (9 by maintainers)
Top Results From Across the Web
Using Linq's Where/Select to filter out null and convert the type ...
In my project I have nullable reference warnings turned to errors, so the commented out line below will not compile. If I do...
Read more >Avoid Check for Null Statement in Java - Baeldung
Learn several strategies for avoiding the all-too-familiar boilerplate conditional statements to check for null values in Java.
Read more >2 Serialization Filtering - Java - Oracle Help Center
An object is deserialized when its serialized form is converted to a copy of the object. It is important to ensure the security...
Read more >Using filters to manipulate data - Ansible Documentation
Defining different values for true/false/null (ternary) ... By default, Ansible fails if a variable in your playbook or command is undefined.
Read more >Use query parameters to customize responses - Microsoft Graph
If a query is failing, one possible cause is failure to encode the query parameter values appropriately. In some cases, you may have...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Nice. I do love the simplicity of Vega-Lite for most scenarios.