frequenz-floss / frequenz-api-weather

gRPC+protobuf specification and Python bindings for the Frequenz Weather API
MIT License
0 stars 8 forks source link

Historical data response without duplicate validity times #116

Open cwasicki opened 4 months ago

cwasicki commented 4 months ago

What's needed?

There are multiple forecasts for the same validity time with different creation times. Usually users only need a single forecast for each validity time.

Proposed solution

There should be an option to remove all duplicate forecasts with the same validity time based on their relation to the creation time. For instance usually forecasts are only available some hours after they were created. This means, when requesting the data, we would only return the validity time with creation time closest to the validity time, but ignoring those where creation time is below a certain user-defined time difference.

Use cases

No response

Alternatives and workarounds

Currently the user has to do the de-duplication.

Additional context

No response

TalweSingh commented 1 week ago

@cwasicki will provide the interface