From 41ecad7b96cd78442b58c44bb267aae6b31e3ec2 Mon Sep 17 00:00:00 2001 From: Justin Flannery <49741340+juftin@users.noreply.github.com> Date: Thu, 24 Jun 2021 08:44:55 -0600 Subject: [PATCH] camply - 0.1.7 (#29) * docker-compose.yml example * feature/booking nights (#25) * feature progress * campsite compilation * silent notification dash * flaking * polish * README.md tidy * test update * bugfix: filter dates before compiling nights --- CHANGELOG.md | 10 +++++++++- Dockerfile | 2 +- camply/__init__.py | 2 +- camply/search/search_recreationdotgov.py | 3 ++- pyproject.toml | 2 +- 5 files changed, 14 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 06dbd586..f8e2dd45 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,7 +9,13 @@ To request new features or bugfixes the [Camply Feedback for v1.0.0 Discussion](https://github.com/juftin/camply/discussions/12) is the best place to go. -## [0.1.6] - 2021-06-24 +## [0.1.7] - 2021-06-24 + +### Fixed + +- Fixed bug that returned matching night stays outside of the search window. + +## [0.1.6] - 2021-06-23 ### Added @@ -82,6 +88,8 @@ place to go. [unreleased]: https://github.com/juftin/camply/compare/main...integration +[0.1.7]: https://github.com/juftin/camply/compare/v0.1.6...v0.1.7 + [0.1.6]: https://github.com/juftin/camply/compare/v0.1.5...v0.1.6 [0.1.5]: https://github.com/juftin/camply/compare/v0.1.4...v0.1.5 diff --git a/Dockerfile b/Dockerfile index ddb34de3..496a3610 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ FROM python:3.8-slim MAINTAINER Justin Flannery -LABEL version="0.1.6" +LABEL version="0.1.7" LABEL description="camply, the campsite finder" COPY . /tmp/camply diff --git a/camply/__init__.py b/camply/__init__.py index d03cd1f3..75503aef 100644 --- a/camply/__init__.py +++ b/camply/__init__.py @@ -6,4 +6,4 @@ camply __init__ file """ -__version__ = "0.1.6" +__version__ = "0.1.7" diff --git a/camply/search/search_recreationdotgov.py b/camply/search/search_recreationdotgov.py index 7cac4955..62f62e6e 100644 --- a/camply/search/search_recreationdotgov.py +++ b/camply/search/search_recreationdotgov.py @@ -135,7 +135,8 @@ def get_all_campsites(self) -> List[AvailableCampsite]: if index + 1 < len(self.campgrounds): sleep(round(uniform(*RecreationBookingConfig.RATE_LIMITING), 2)) campsite_df = self.campsites_to_df(campsites=found_campsites) - compiled_campsite_df = self._consolidate_campsites(campsite_df=campsite_df, + campsite_df_validated = self._filter_date_overlap(campsites=campsite_df) + compiled_campsite_df = self._consolidate_campsites(campsite_df=campsite_df_validated, nights=self.nights) compiled_campsites = self.df_to_campsites(campsite_df=compiled_campsite_df) return compiled_campsites diff --git a/pyproject.toml b/pyproject.toml index f3587237..37ec8aaf 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "camply" -version = "0.1.6" +version = "0.1.7" description = "camply, the campsite finder ⛺️" authors = ["Justin Flannery "] maintainers = ["Justin Flannery "]