Klimatbyran / beta

New repo for new layout
2 stars 3 forks source link

Total sum not correct #188

Open Almendra-ab opened 2 weeks ago

Almendra-ab commented 2 weeks ago

Adding scope 1, 2 and 3 does not give the same value as what is displayed

https://beta.klimatkollen.se/foretag/latour-Q6060753

Greenheart commented 2 weeks ago

This seems to be a similar cause as #190, with potential fix as mentioned in there.

And even more long term, we should combine all data on the backend to make it consistent. This would help us avoid the inconsistencies when reading data from many sources, and in different priorities. Instead, we should get one number for each data point, and a verified: boolean | URL to make it clear where the data came from.

Greenheart commented 2 weeks ago

Based on what I can see in the API responses, as well as in the facit data, this problem could potentially be resolved by re-running the report (to include the latest facit data which seems to include the updated numbers which gives the correct total).

The previous version of the facit data seemed to have no value for the scope 3 total, which explains why the frontend relied on wikidata to get the scope 3 total instead. And because wikidata is completely unreliable until https://github.com/Klimatbyran/garbo/issues/169 has been resolved, we got a bad result on the website.