File / lines: src/gmaps_scraper/models.py (no opening-hours field); src/gmaps_scraper/place_scraper.py (no extractor)
Problem: The model only has status: str | None, which captures strings like "Open ⋅ Closes 10 PM". There is no field for the full weekly schedule that Google displays in the About/Overview panel.
Why it matters: Opening hours are core place metadata. The current status string is transient (changes with time-of-day) and not machine-parseable.
Suggested fix:
- Add an
opening_hours field to PlaceDetails (e.g., list of {day, hours, is_open_24h}).
- Extract it from the About panel heading aliases for "Hours", "Opening hours", 営業時間, etc.
- Add tests with fixtures for English and non-English hour panels.
- Keep the raw
status field intact for backward compatibility.
Difficulty: medium
Impact: Medium — adds commonly requested structured data without breaking existing output.
File / lines:
src/gmaps_scraper/models.py(no opening-hours field);src/gmaps_scraper/place_scraper.py(no extractor)Problem: The model only has
status: str | None, which captures strings like"Open ⋅ Closes 10 PM". There is no field for the full weekly schedule that Google displays in the About/Overview panel.Why it matters: Opening hours are core place metadata. The current
statusstring is transient (changes with time-of-day) and not machine-parseable.Suggested fix:
opening_hoursfield toPlaceDetails(e.g., list of{day, hours, is_open_24h}).statusfield intact for backward compatibility.Difficulty: medium
Impact: Medium — adds commonly requested structured data without breaking existing output.