Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow partial days in the date window #100

Merged
merged 4 commits into from
Sep 24, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
# Changelog

** 1.4.9
* Allow partial days in the `date_window_size` config value [#100](https://github.com/singer-io/tap-stripe/pull/100)

** 1.4.8
* Reverts 1.4.7 [#82](https://github.com/singer-io/tap-stripe/pull/82)

Expand All @@ -18,7 +22,7 @@
* Revert 1.4.2 changes from #59 [#60](https://github.com/singer-io/tap-stripe/pull/60)
* Remove invalid and unused schema pieces [#60](https://github.com/singer-io/tap-stripe/pull/60)

** 1.4.2
** 1.4.2
* Revert 1.4.1 [#59](https://github.com/singer-io/tap-stripe/pull/59)

** 1.4.1
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

setup(
name="tap-stripe",
version="1.4.8",
version="1.4.9",
description="Singer.io tap for extracting data",
author="Stitch",
url="http://singer.io",
Expand Down
6 changes: 4 additions & 2 deletions tap_stripe/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -426,9 +426,11 @@ def sync_stream(stream_name):

with Transformer(singer.UNIX_SECONDS_INTEGER_DATETIME_PARSING) as transformer:
end_time = dt_to_epoch(utils.now())
window_size = int(Context.config.get('date_window_size', DEFAULT_DATE_WINDOW_SIZE))

window_size = float(Context.config.get('date_window_size', DEFAULT_DATE_WINDOW_SIZE))

if DEFAULT_DATE_WINDOW_SIZE != window_size:
LOGGER.info('Using non-default date window size of %d', window_size)
LOGGER.info('Using non-default date window size of %.2f',window_size)
start_window = bookmark

# NB: Immutable streams are never synced for updates. We've
Expand Down