WIP: Make proj-addre one-to-many data and load into database. #497
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adds an "apiconn" object for the prescat. Currently this just loads the file from disk, but in the future this can be the class that checks for newly uploaded data in an online folder that admins can put data into
Adds a function to the base_project.py apiconn that uses the split address function to create a csv file of the one-to-many project to addresses.
Moves the split address function out of ingestion and into tools, since it's not used only in ingestion
Fixes bug in the MarApiConn - adds a method to query api using address string instead of generic string. Helps eliminate false positives.
Changes references to find_location to instead be find_addr_string to eliminate false positives
Fixes bug in address splitting code that found
and
inMarland
orRandolph
. Changed split string to' and '
.Adds proj_addre table to database
DHCD and DCHousing ApiConn methods also create
_addre.csv
files for uploadEntity resolution now done via the one to many mapping of addresses - if any of the addresses match, assumes the whole project matches.
To test
python/housinginsights/sources/
folder runpython prescat.py
(needs to be added to the options list in get_api_data.py, but should be ready to work there)/python/scripts
:python load_data.py docker --update-only proj_addre
python get_api_data.py
with the code options edited to request theDCHousing
anddhcd
modules.