GeoDaCenter / GeoDaCenter/spatial_access
Coverage doesn't use specified category field (edge case)
- Dominant language
- Python
- Stars
- 40
- Forks
- 11
- PR merge metrics
- No merged PRs in 30d
Description
Low priority, but probably worth addressing eventually.
Scenario: an input destination file has a field named "category", but the user points to a different a field (e.g., "category_1") as containing category values.
The user also provides a list of values to the "categories" parameter of the Coverage class constructor.
It looks like the code never maps the internal data model's "category" field to the one provided by the user. It looks for the category values in the list provided by the user in the destination file's "category" field instead of the field specified and can't find them.
The main scenario I could see this coming up in is where a user has a legacy field "category", and then a current field called "category_facility" or "category_1" etc containing the 'real' category values. I've seen this kind of thing pretty frequently given the poor data management practices out there, the difficulty of updating schemas...
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.