Metric evaluation on 'DAY' interval during a Daylight Savings Time switch gives zero

Let’s create a facility on 7.10:

var facility = Facility.create({});

and define the following metric, equal to one before the 15th of the month, null otherwise:

var simpleMetric = SimpleMetric.make({
    'id': 'Identity_Facility',
    'name': 'Identity',
    'srcType': 'Facility',
    'expression': 'timeComponent("DAY", start()) < 15 ? identity(1): null'
});

with the below function which evaluates the metric on facility between two dates using the Roman time zone:

function vizIdentity(start, end) {
    let result = Facility.evalMetricsWithMetadata(
        {
            ids: [facility.id],
            expressions: ['Identity'],
            start: start.toString(), 
            end: end.toString(), 
            interval: 'DAY', 
            timeZone: 'Europe/Rome'
        }, 
        [ simpleMetric]
    );

    c3Viz(result);
}

When visualizing in March 2018 between the 10th and the 20th, I get (expected):

vizIdentity(Date('2018-03-10'), Date('2018-03-20'));


However, changing the end date to the 30th, I get a flat zero:

vizIdentity(Date('2018-03-10'), Date('2018-03-30'));

image

Is this expected (in 2018 the DST switch occurred on the 25th)?

This looks like a bug to me, can you file a ticket with platform team?

Just filed a ticket.

The problem is with c3Viz which does not display the data (but it’s there).

Also when evaluating with an interval ‘HOUR’, there is an exception: ‘Length of field missing mismatch. expected=239, actual=240’.
This other issue was fixed on 7.10.