I have a script that sets the dataSources
and series
props on an XYChart based on dropdown selections. I'm calling the script via a Property Change Script on a dropdown value property. The generation script runs several named queries and creates dicts that get assigned to the dataSources and series values on the chart.
Sometimes this works and the chart displays, but sometimes I get "No series properly configured." on the chart component, and this error in the console:
16:43:57.071 [Browser Thread: c0dbb329-5bde-48c5-8dc6-ebfd1c87c96e] ERROR Perspective.Designer.Workspace - level: LEVEL_ERROR
message: "components.XYChart: No series configured."
line_number: 2
source: "https://spbkyigapp01:8043/res/perspective/js/PerspectiveClient.ef24a2d510d2934354db.js"
This happens both in the designer and in the browser. In the designer the property values look fine. There are no property bindings on the chart itself, but this still seems like a timing issue. If I toggle preview mode off and on again, the chart fixes itself.
What could be causing this, and is there a workaround?