robbi5 / kleineanfragen

Collecting kleine Anfragen from Parlamentsdokumentationssystemen for easy search- and linkability
https://kleineanfragen.de
MIT License
43 stars 9 forks source link

API yields null as values for startDate in LegislativeTerm objects. #110

Closed grindhold closed 7 years ago

grindhold commented 7 years ago

In here, you can find two (maybe more) legislative term objects that have NULL as value for their startDate fields.

https://api.kleineanfragen.de/oparl/v1/bodies

https://api.kleineanfragen.de/oparl/v1/body/sl/term/15 https://api.kleineanfragen.de/oparl/v1/body/sl/term/14

robbi5 commented 7 years ago

Yep, those are currently set manually. It's a bit complicated to find out the real dates when legislative terms begin, but I'll try to add the missing ones in the next few days.

grindhold commented 7 years ago

Ah okay, i can imagine digging for such dates to be bothersome. It's okay for an OParl-endpoint to have missing data at some points, but then the whole key-value-pair should be skipped.

Citation from the spec [german]:

JSON erlaubt es grundsätzlich, Eigenschaften mit dem Wert null zu versehen. Eigenschaften sollten nicht mit dem Wert null ausgegeben werden, wenn zu einer Eigenschaft keine Daten vorliegen. Obligatorische Eigenschaften dürfen nicht den Wert null haben.
grindhold commented 7 years ago

thanks :+1: