openstate / open-cultuur-data

The back- and front-end code that powers the Open Cultuur Data API
http://opencultuurdata.nl/
28 stars 18 forks source link

Add tests for National Archive Beeldbank and check for faulty dates #87

Closed breyten closed 9 years ago

breyten commented 9 years ago

As discussed in #73

justinvw commented 9 years ago

You got rit of the messy dates, great!

While testing I discovered a separate issue with the National Archive Beeldbank source: their OpenSearch endpoint frequently returns error responses without providing a proper HTTP status code (see the example below). Lowering the number of requested items also doesn't help. We should probably contact them about this. Do you want to do this?

$ curl -i "http://www.gahetna.nl/beeldbank-api/opensearch/?q=\"*:*\"&count=50&startIndex=9223"
HTTP/1.1 200 OK
Date: Fri, 23 Jan 2015 21:12:31 GMT
Server: Apache
P3P: CP=CAO PSA OUR
Content-Length: 609
Content-Type: application/xml

<?xml version="1.0" encoding="UTF-8"?> <rss version="2.0"
      xmlns:opensearch="http://a9.com/-/spec/opensearch/1.1/"
      xmlns:memorix="http://www.pictura-dp.nl/memorix/3.0"
      xmlns:dc="http://purl.org/dc/elements/1.1/"
      xmlns:atom="http://www.w3.org/2005/Atom">
   <channel>
    <title>Beeldbank Nationaal Archief</title><link>http://www.gahetna.nl/</link><description>OpenSearch API voor de Beeldbank van het Nationaal Archief</description>      <item>
            <title>An Error of type 1000 has occurred</title>
            <description>Read timed out after 10 seconds</description>
        </item>
    </channel>
</rss>