Repository navigation
feat: add hotel data parser with cleanup, validation, and db integration - #28
Merged
Merged
Conversation
bhuvanh66
force-pushed
the
5-hotel-data-parser
branch
2 times, most recently
from
September 30, 2026 17:50
2cdf285 to
da68bbb
Compare
bhuvanh66
force-pushed
the
5-hotel-data-parser
branch
2 times, most recently
from
September 30, 2026 17:58
09fcce6 to
32ef27b
Compare
maria1neu
force-pushed
the
5-hotel-data-parser
branch
from
September 30, 2026 18:27
32ef27b to
b282caf
Compare
selvarajuv
force-pushed
the
5-hotel-data-parser
branch
from
September 30, 2026 23:20
40031c0 to
a43cbdb
Compare
selvarajuv
force-pushed
the
5-hotel-data-parser
branch
from
September 30, 2026 23:26
a43cbdb to
a3bf068
Compare
selvarajuv
approved these changes
Oct 5, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Closes #5
We created a HotelDataParser class to centralize running the parser and the required cleaning and validation steps. We have a run function which should just be a command to initiate the hotel parser and it returns the final transformed data. (.venv) bhuvanhospet@Bhuvans-MacBook-Pro backend % export PYTHONPATH=src
(.venv) bhuvanhospet@Bhuvans-MacBook-Pro backend % python src/parsers/hotel_data_parser.py
--input data/2022.csv
--hotel-name "Sample Hotel"
--db-url "postgresql+psycopg2://foresight:foresight@localhost:5433/foresight_db"
2026-09-28 21:08:13,291 - INFO - Hotel data parser started.
2026-09-28 21:08:13,291 - INFO - Loading hotel data...
2026-09-28 21:08:13,295 - INFO - File loaded: data/2022.csv
2026-09-28 21:08:13,295 - INFO - Rows: 365
2026-09-28 21:08:13,295 - INFO - Columns: 32
2026-09-28 21:08:13,295 - INFO - Cleaning hotel data...
also we need to put data in the backend/data folder (added to gitignore)
feat— new featurefix— bug fixdocs— documentation onlyrefactor— code change that neither fixes a bug nor adds a featureperf— performance improvementtest— adding or updating testschore/build/ci— tooling, deps, or pipeline changesChanges
Database migrations
just migrate-create "...")just migrate) and rolls back (just migrate-down)Checklist
just lint) and code is formatted (just format)just hooksinstalled).env.examplewhere relevantjust dev) and verified the API athttp://localhost:8000/docsHow to test
Notes for reviewers