Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Amount has at most 2 decimals #91

Open
jpmckinney opened this issue Aug 11, 2023 · 1 comment
Open

Amount has at most 2 decimals #91

jpmckinney opened this issue Aug 11, 2023 · 1 comment
Labels
field checks Relating to field-level checks new check

Comments

@jpmckinney
Copy link
Member

Need to check whether some countries could have more. This check might not apply to unit values.

Noticed that some publishers have potential floating point issues, like 28274.399999999998

For example, at time of writing this package has that number: https://contratacionesabiertas.osce.gob.pe/api/v1/releasesAfter?format=json&order=desc&searchAfter=1683120791420%2C1209600000000%2Cocds-dgv273-seacev2-951934-2023-05-03T08%3A33%3A11.420620-05%3A00&first=ocds-dgv273-seacev3-2023-10432-11-2023-07-28T08%3A31%3A20.871956-05%3A00

Process loads data with simplejson to avoid floating point issues. Pelican would need to do similar.

@jpmckinney jpmckinney added field checks Relating to field-level checks new check labels Aug 11, 2023
@jpmckinney
Copy link
Member Author

I also see numbers like 276000.0058 in DR's dataset.

In some cases, DR cancels contracts with many decimal places (because the decimal was misplaced – usually where a thousands separator should be).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
field checks Relating to field-level checks new check
Projects
None yet
Development

No branches or pull requests

1 participant