Skip to content

Commit 9a5fdbd

Browse files
committed
add until date to commitsstream
1 parent 7da02d7 commit 9a5fdbd

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

tap_github/repository_streams.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1078,6 +1078,17 @@ class CommitsStream(GitHubRestStream):
10781078
state_partitioning_keys: ClassVar[list[str]] = ["repo", "org"]
10791079
ignore_parent_replication_key = True
10801080

1081+
def get_url_params(
1082+
self,
1083+
context: Context | None,
1084+
next_page_token: Any | None, # noqa: ANN401
1085+
) -> dict[str, Any]:
1086+
"""Return a dictionary of values to be used in URL parameterization."""
1087+
assert context is not None, f"Context cannot be empty for '{self.name}' stream."
1088+
params = super().get_url_params(context, next_page_token)
1089+
params["until"] = "2025-07-05"
1090+
return params
1091+
10811092
def post_process(self, row: dict, context: Context | None = None) -> dict:
10821093
"""
10831094
Add a timestamp top-level field to be used as state replication key.

0 commit comments

Comments
 (0)