Building the 411 for air quality in the United States: a texting platform accessible to all, that provides actionable local information to protect your and your community.
Right now, when a sensor moves, we don't refresh the mapping between it and each zipcode near it — we just add to that mapping. This is obviously wrong. We should delete the mapping and start fresh.
This is actually relatively simple to implement and I'd be happy to walk someone through it. It just involves updating the _relationships_sync() function in airq.sync.purpleair so that, before processing a given sensor, we delete all its existing relationships.
Right now, when a sensor moves, we don't refresh the mapping between it and each zipcode near it — we just add to that mapping. This is obviously wrong. We should delete the mapping and start fresh.
This is actually relatively simple to implement and I'd be happy to walk someone through it. It just involves updating the
_relationships_sync()
function inairq.sync.purpleair
so that, before processing a given sensor, we delete all its existing relationships.