Cannot support processing c3.love.timeseries.impl.DoubleTimeseries

#1

I’ve a metric of the form that simply aims to return 1 in interval when there is ServiceAgreementCharacteristicSet in the interval

{
    "id": "Test1_Facility",
    "name": "Test1",
    "description": "",
    "srcType": "Facility",
    "path": "servicePoints.serviceAgreements",
    "tsDecl": {
        "data": "characteristics",
        "filter": "code.id=='testCode'",
        "value": "identity(1)",
        "treatment": "PREVIOUS",
        "start": "start",
        "end": "end"
    },
    "unit": {
        "id": "dimensionless"
    }
}

When I try to evaluate it I hit the following error:

Error: c3.love.exceptions.C3RuntimeException: c3.love.exceptions.C3RuntimeException: MetricEngine error : c3.love.exceptions.C3RuntimeException: 
Cannot support processing c3.love.timeseries.impl.DoubleTimeseries
	at c3.love.timeseries.TimeseriesUtils.throwError(TimeseriesUtils.java:503)
	at c3.love.timeseries.TimeseriesUtils.getValue(TimeseriesUtils.java:914)
	at c3.service.metric.AsTimeseriesGroup.evaluateFromObjs(AsTimeseriesGroup.java:349)
	at c3.service.metric.AsTimeseriesGroup.evaluate(AsTimeseriesGroup.java:186)
	at c3.service.metric.AsTimeseriesOptimizer.evaluate(AsTimeseriesOptimizer.java:79)
	at c3.service.metric.AsTimeseries.getEvalResult(AsTimeseries.java:114)
	at c3.service.metric.AsTimeseries.asTimeseries(AsTimeseries.java:46)
	at c3.service.metric.SimpleMetricEvaluator.evaluateAsTimeseriesBasedMetric(SimpleMetricEvaluator.java:577)

What does this error means?

1 Like
#2

It turns out I cannot use identity function which returns a timeseries. the following works fine:

"value": "1",