socrata / opendatanetwork.com

The Open Data Network
https://www.opendatanetwork.com/
Other
19 stars 12 forks source link

Investigate why Michigan data isn't showing up #474

Closed chrismetcalf closed 8 years ago

chrismetcalf commented 8 years ago

Can you take a look at why @aliciatb's new Michigan data isn't showing up properly in staging?

http://opendatanetwork-staging.herokuapp.com/region/1600000US2680700/Troy_MI/finance/michigan.finance.liquidity_ratio/2015?

/cc @kyleahall

kyleahall commented 8 years ago

@ToshMeston Do we have a sense of when this will be available in prod? The customer is extremely eager to see it.

ToshMeston commented 8 years ago

I don't know anything about how or where the data is stored. Assigning to Lane. @chrismetcalf @kyleahall

aaasen commented 8 years ago

Michigan data shows up here so this is an issue with the front end: http://api.opendatanetwork.com/data/v1/availability?app_token=cQovpGcdUT1CSzgYk0KPYdAI0&entity_id=0500000US26163

Just an issue of adding a Michigan source to data sources.

I'm in Ecuador with just a phone and spotty internet so I can't be of much help.

desingh-rajan commented 8 years ago

In master dataset

[ { "name" : "Troy, MI", "id" : "1600000US2680700", "type" : "place", "population" : "81700"} ]

In michigan's dataset

[{"id":"1600000US2680700","local_unit_id":"3875","name":"TROY CITY","type":"city"}...]

  1. Change type => place in michigan dataset.
  2. Change type => city/county/village/.. appropriately in master dataset.
  3. Or if entityType is 'place' then filter by

type in ['place', 'city', 'village', 'county']

https://github.com/socrata/odn-backend/blob/master/app/data/map/new.js#L81

    const baseQuery = new SOQL(dataset.url)
        .token(token)
        .whereIn('type', [entityType, _.last(entityType.split('.'))])
        .equal('variable', _.last(variable.id.split('.')))
        .equals(constraints);
haibeeb commented 8 years ago

Kicking this over to @kyleahall as a dataset fix.

kyleahall commented 8 years ago

Dataset is updated. Closing out.