marlon360 / rki-covid-api

🦠🇩🇪📈 An API for the spread of covid-19 in Germany. Data from Robert-Koch-Institut.
https://api.corona-zahlen.org/
Creative Commons Attribution 4.0 International
250 stars 50 forks source link

Problems with the API #483

Closed codingcat2468 closed 1 year ago

codingcat2468 commented 1 year ago

Hi, in the last days, I've discovered several problems with the API. All endpoints return strange values for lastUpdate and lastCheckedForUpdate. These values are always like 2022-11-24T16:50:30.404Z. Looks like the server updated a few days ago last time and the responses are loaded from cache. Also, an app on my phone always shows an JSON parsing error because the API response is an empty string. The documentations page sometimes returns an error message like this or does not even load: Screenshot 2022-11-26 at 12-16-34 api corona-zahlen org 502 Bad gateway

What could be the reason for this?

marlon360 commented 1 year ago

Thanks for reporting!

These are the errors in the logs:

2022-11-26T12:25:17.882997032Z at Parser.emit (node:events:513:28) 2022-11-26T12:25:17.882990921Z at Parser. (/app/src/data-requests/vaccination.ts:355:31) 2022-11-26T12:25:17.882985470Z TypeError: Cannot read properties of undefined (reading 'total')

Rubber1Duck commented 1 year ago

I am still in vaccation, it seems that the vaccination Parser must be rewritten or patched, because the headline of the cvs files are renamed! I will be back after 2.Advent only then could I take care of it. Sorry for that!

wagnerand commented 1 year ago

The headers didn't change, but they added 5th and 6th vaccination: https://github.com/robert-koch-institut/COVID-19-Impfungen_in_Deutschland/issues/20

codingcat2468 commented 1 year ago

Hi, all endpoints are working again, thanks for fixing! Looks like the reason was really the vaccination parser that let the app crash. I just have noticed that a few values in the vaccination endpoint are wrong. The quote property of the 1st vaccination looks strange: 520094.64 and the vaccinated property of the secondVaccination is 1941. Maybe the change in the vaccination parser caused some problems with certain values?

foaryon commented 1 year ago

Hi, all endpoints are working again, thanks for fixing! Looks like the reason was really the vaccination parser that let the app crash. I just have noticed that a few values in the vaccination endpoint are wrong. The quote property of the 1st vaccination looks strange: 520094.64 and the vaccinated property of the secondVaccination is 1941. Maybe the change in the vaccination parser caused some problems with certain values?

2nd and 4th vaccination not working for me.

marlon360 commented 1 year ago

The vaccination parser has to be adjusted.. #484