Open Jabolol opened 1 month ago
I think that's fine for now. The nature of dbt makes it very easy to change this in the future.
FWIW, in the timeseries_metrics marts, we introduce a unit
column for this reason, because there are different unit measures for different metrics.
https://github.com/opensource-observer/oso/blob/main/warehouse/metrics_mesh/models/timeseries_metrics_by_project_v0.sql
It wouldn't hurt to introduce a nullable unit
column in the event table to capture this kind of information.
What is it?
Open Collective currently returns currency data in local currencies without a standardized parameter. This conflicts with the universal event table's definition, where the
amount
field assumes a consistent currency.After discussing with the team, potential solutions include: collecting only
USD
transactions for consistency, maintaining a daily table of currency exchange rates in BigQuery as a source of truth, or introducing an additional API to handle conversions.Edit: For now, we will filter out all non
USD
transactions