Issues with geo.totalDistance() when grouping

I’m using the experimental geo.totalDistance() function and I have trouble getting it properly working when grouping data.

This is my initial query:

import "array"
import "experimental/geo"

option geo.units = {distance: "km"}

data =
    from(bucket: "gpstracking")
        |> range(start: v.timeRangeStart, stop: v.timeRangeStop)
        |> filter(fn: (r) => r._measurement == "gpsd")
        |> filter(fn: (r) => r._field == "lat" or r._field == "lon")
        |> filter(fn: (r) => r._value != 0)
    |> geo.shapeData(latField: "lat", lonField: "lon", level: 10)
    |> geo.totalDistance()

In return, I get the following result:

table_ _measurement _value s2_cell_id
0 gpsd 6.882889427286594 135b03
1 gpsd 9.271066109071215 135b05
2 gpsd 2.8307053681739958 135b07
3 gpsd 5.7607594561117175 135b09
4 gpsd 8.860840318102479 135b0f

When summing up all the _value fields manually, the result is what I expect (~33.6).

But when I enhance the query like below, I get an utterly wrong calculated number:

    |> geo.shapeData(latField: "lat", lonField: "lon", level: 10)
    |> group(columns: ["_measurement"], mode:"by")    
    |> geo.totalDistance()
table _measurement _value
0 gpsd 71.39178328323679

Can anyone help me to solve that mystery? My goal is to have all the _values summed up in the query.