koopjs / koop-provider-ckan

CKAN provider for Koop (experimental).
Other
4 stars 5 forks source link

Ckan Provider Failing #5

Closed dmartine closed 9 years ago

dmartine commented 9 years ago

Using version Ckan provider 0.0.8

  1. Installed koop sample app with PostgreSQL 9.4 and added extension for postgis.
  2. Registered provider for data.hdx.rwlabs.org.
  3. Used http://localhost:1337/ckan/rwlabs/ourairports-ind and received TypeError: Cannot call method 'forEach' of undefined at Object.exports.fromCSV. ckanerrors

I noticed http://koop.dc.esri.com/ckan/rwlabs/ourairports-ind works. Is that running a different version of ckan? Also tried on @jgravois machine and was able to produce the same results.

jgravois commented 9 years ago

on my machine, this shows up in the PostGres logs, even though a call to http://localhost:1337/ckan returns the appropriate serviceId

STATEMENT:  select count(*) as count from "ckan:services"
ERROR:  relation "ckan:services" does not exist at character 31
chelm commented 9 years ago

@jgravois You might need to register a ckan instance first. I think there's an issue with this provider where it doesn't handle the case when no providers are registered yet.

I get the same error that @dmartine reports and it due to getting a 404 at https://data.hdx.rwlabs.org/ourairports-ind - we'll need to add support for catching 404s from CKAN

jgravois commented 9 years ago

i've definitely got the ckan instance registered. how is koop.dc.esri.com already handling this 404?

chelm commented 9 years ago

@jgravois so the reason why koop.dc handles that one is because its cached, as soon as its dropped that link will break.

jgravois commented 9 years ago

:bulb: thx @chelm

chelm commented 9 years ago

@jgravois @dmartine PR #6

dmfenton commented 9 years ago

Going to handle this in issue #8