CodeForBc / airbnb-regulation

MIT License
4 stars 2 forks source link

Features/ingestion/connect harvester to database #44

Open immangat opened 1 month ago

immangat commented 1 month ago

Description

Issue Link: https://github.com/orgs/CodeForBc/projects/2/views/1?pane=issue&itemId=64613853&issue=CodeForBc%7Cairbnb-regulation%7C24

This PR connects the harvester with the database. Instead of storing harvested listings in CSV files, they will now be saved directly to the database. Additionally, this PR fixes a bug that previously prevented restarting of scraping unless the server was restarted.

The PR also removes manual duplication checking for listings, as this functionality is now handled by the ORM. Note: Future implementation will need to include time-based listings storage.

The listings model has been updated to include additional fields.

Type of Change

Please delete options that are not relevant.

How Has This Been Tested?

The changes have been verified through unit tests covering both the database pipeline and the bug fixes.

Checklist

Before submitting your pull request, please verify you have completed the following:

Additional Notes

Due to changes in the Listings model, there may be impacts on the policy module as it pulls data from the database.