Skip to content

Commit

Permalink
Include closed milestones in extraction.
Browse files Browse the repository at this point in the history
  • Loading branch information
TrishGillett committed Sep 10, 2024
1 parent af86ecd commit a11c1a2
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions tap_github/repository_streams.py
Original file line number Diff line number Diff line change
Expand Up @@ -635,6 +635,16 @@ class MilestonesStream(GitHubRestStream):
state_partitioning_keys: ClassVar[list[str]] = ["repo", "org"]
ignore_parent_replication_key = True

def get_url_params(
self, context: dict | None, next_page_token: Any | None
) -> dict[str, Any]:
"""Return a dictionary of values to be used in URL parameterization."""
assert context is not None, f"Context cannot be empty for '{self.name}' stream."
params = super().get_url_params(context, next_page_token)
# Fetch all milestones, regardless of state (open, closed).
params["state"] = "all"
return params

schema = th.PropertiesList(
# Parent Keys
th.Property("repo", th.StringType),
Expand Down

0 comments on commit a11c1a2

Please sign in to comment.