Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

don't print names without UTF-8 handling (better, don't print names\!)

  • Loading branch information...
commit b0e7112b8b42fd130522664651163f2fd5c8c15b 1 parent 1abf00d
@JoeGermuska JoeGermuska authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 dataprocessing/
4 dataprocessing/
@@ -58,12 +58,12 @@ def push(state, slug, obj):
counties = collection.find({ 'sumlev': config.SUMLEV_COUNTY }, fields=['geoid', 'metadata.NAME', 'metadata.COUNTY'], sort=[('metadata.NAME', 1)])
for county in counties:
- print 'Deploying county subdivisions lookup for %s' % county['metadata']['NAME']
+ print 'Deploying county subdivisions lookup for %s' % county['geoid']
county_subdivisions = collection.find({ 'sumlev': config.SUMLEV_COUNTY_SUBDIVISION, 'metadata.COUNTY': county['metadata']['COUNTY'] }, fields=['geoid', 'metadata.NAME', 'metadata.COUNTY_SUBDIVISION'], sort=[('metadata.NAME', 1)])
county_subdivisions = [(c['metadata']['NAME'], c['geoid']) for c in county_subdivisions]
push(state, 'county_subdivisions_%s' % county['geoid'], county_subdivisions)
- print 'Deploying tracts lookup for %s' % county['metadata']['NAME']
+ print 'Deploying tracts lookup for %s' % county['geoid']
tracts = collection.find({ 'sumlev': config.SUMLEV_TRACT, 'metadata.COUNTY': county['metadata']['COUNTY'] }, fields=['geoid', 'metadata.NAME'], sort=[('metadata.NAME', 1)])
tracts = [(c['metadata']['NAME'], c['geoid']) for c in tracts]
push(state, 'tracts_%s' % county['geoid'], tracts)
Please sign in to comment.
Something went wrong with that request. Please try again.