hotosm / galaxy-api

Backend to fetch data from Underpass
https://galaxy-api.hotosm.org/latest/redoc
GNU Affero General Public License v3.0
14 stars 5 forks source link

ValidationError: 6 validation errors for UserStatistics #223

Closed sentry-io[bot] closed 2 years ago

sentry-io[bot] commented 2 years ago

Sentry Issue: GALAXY-API-D

ValidationError: 6 validation errors for UserStatistics
addedBuildings
  none is not an allowed value (type=type_error.none.not_allowed)
modifiedBuildings
  none is not an allowed value (type=type_error.none.not_allowed)
addedHighway
  none is not an allowed value (type=type_error.none.not_allowed)
modifiedHighway
  none is not an allowed value (type=type_error.none.not_allowed)
addedHighwayMeters
  none is not an allowed value (type=type_error.none.not_allowed)
modifiedHighwayMeters
  none is not an allowed value (type=...
(27 additional frame(s) were not displayed)
...
  File "newrelic/api/function_trace.py", line 166, in literal_wrapper
    return wrapped(*args, **kwargs)
  File "API/osm_users.py", line 41, in user_statistics
    return user_stats.get_statistics_with_hashtags(params)
  File "/home/ubuntu/galaxy-api/./src/galaxy/app.py", line 529, in get_statistics_with_hashtags
    summary = [UserStatistics(**r) for r in result]
  File "/home/ubuntu/galaxy-api/./src/galaxy/app.py", line 529, in <listcomp>
    summary = [UserStatistics(**r) for r in result]
  File "pydantic/main.py", line 406, in __init__
    raise validation_error

Exception in ASGI application