Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug fix: implement new dict that ignores casing on key names #27

Open
nvkelso opened this issue Jan 11, 2012 · 1 comment
Open

bug fix: implement new dict that ignores casing on key names #27

nvkelso opened this issue Jan 11, 2012 · 1 comment
Assignees

Comments

@nvkelso
Copy link
Collaborator

nvkelso commented Jan 11, 2012

This didn't entirely work:
#24

Instead of being specific everywhere, make a new general dict that abstracts this.

Was:
place = dict( [ (key.lower(), value) for (key, value) in place.items() ] )

With other places that assume lowercase like:
line 180 in init.py
name = row['name'].decode('utf-8')

@ghost ghost assigned migurski Jan 11, 2012
@nvkelso
Copy link
Collaborator Author

nvkelso commented Jan 11, 2012

This also broke the export retaining the values in columns that aren't lowercase key names.

For instance, "name", "lat", "long" etc values are pushed out. But "NAME" would result in "" values in the correctly cased column (NAME in, NAME out).

"type": "Feature",
"properties": {
"sizeClass": "",
"long": -73.980019999999996,
"point_size": 8,
"name": "New York",
"UNLOCKED": "",
"font_file": "../fonts/Arial.ttf",
"zoom_start": 1,
"rank": 1,
"LABEL": "",
"STATE": "",
"LINK": "",
"joinMe": "",
"TRACKBACK": "",
"lat": 40.749980000000001,
"font_size": 9,
"REGION": "",
"population": 19040000
}
},

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants