diff --git a/CHANGELOG.md b/CHANGELOG.md index e37062a68f..cfa0adf0b4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,14 +1,37 @@ # Changelog -## [Unreleased](https://github.com/MarquezProject/marquez/compare/0.42.0...HEAD) +## [Unreleased](https://github.com/MarquezProject/marquez/compare/0.43.0...HEAD) +## [0.43.0](https://github.com/MarquezProject/marquez/compare/0.42.0...0.43.0) - 2023-12-15 ### Added -* API: support `DatasetEvent` [`#2641`](https://github.com/MarquezProject/marquez/pull/2641) [@pawel-big-lebowski]( https://github.com/pawel-big-lebowski) - *Save into Marquez model datasets sent via `DatasetEvent` event type -* API: support `JobEvent` [`#2661`](https://github.com/MarquezProject/marquez/pull/2661) [@pawel-big-lebowski]( https://github.com/pawel-big-lebowski) - *Save into Marquez model jobs and datasets sent via `JobEvent` event type. -* API: support streaming jobs [`#2682`](https://github.com/MarquezProject/marquez/pull/2682) [@pawel-big-lebowski]( https://github.com/pawel-big-lebowski) - *Creates job version and reference rows at the beginning of the job instead of on complete. Updates job version within the run if anything changes. +* API: refactor the `RunDao` SQL query [`#2685`](https://github.com/MarquezProject/marquez/pull/2685) [@sophiely](https://github.com/sophiely) + *Improves the performance of the SQL query used for listing all runs.* +* API: refactor dataset version query [`#2683`](https://github.com/MarquezProject/marquez/pull/2683) [@sophiely](https://github.com/sophiely) + *Improves the performance of the SQL query used for the dataset version.* +* API: add support for a `DatasetEvent` [`#2641`](https://github.com/MarquezProject/marquez/pull/2641) [`#2654`](https://github.com/MarquezProject/marquez/pull/2654) [@pawel-big-lebowski]( https://github.com/pawel-big-lebowski) + *Adds a feature for saving into the Marquez model datasets sent via the `DatasetEvent` event type. Includes optimization of the lineage query.* +* API: add support for a `JobEvent` [`#2661`](https://github.com/MarquezProject/marquez/pull/2661) [@pawel-big-lebowski]( https://github.com/pawel-big-lebowski) + *Adds a feature for saving into the Marquez model jobs and datasets sent via the `JobEvent` event type.* +* API: add support for streaming jobs [`#2682`](https://github.com/MarquezProject/marquez/pull/2682) [@pawel-big-lebowski]( https://github.com/pawel-big-lebowski) + *Creates job version and reference rows at the beginning of the job instead of on complete. Updates the job version within the run if anything changes.* +* API/spec: implement upstream run-level lineage [`#2658`](https://github.com/MarquezProject/marquez/pull/2658) [@julienledem](https://github.com/julienledem) + *Returns the version of each job and dataset a run is depending on.* +* API: add `DELETE` endpoint for dataset tags [`#2698`](https://github.com/MarquezProject/marquez/pull/2698) [@davidsharp7](https://github.com/davidsharp7) + *Creates a new endpoint for removing the linkage between a dataset and a tag in `datasets_tag_mapping` to supply a way to delete a tag from a dataset via the API. +* Web: add a dataset drawer [`#2672`](https://github.com/MarquezProject/marquez/pull/2672) [@davidsharp7](https://github.com/davidsharp7) + *Adds a drawer to the dataset column view in the GUI.* + +### Fixed: +* Client/Java: change url path encoding to match jersey decoding [`#2693`](https://github.com/MarquezProject/marquez/pull/2693) [@davidjgoss](https://github.com/davidjgoss) + *Swaps out the implementation of `MarquezPathV1::encode` to use the `UrlEscapers` path segment escaper, which does proper URI encoding.* +* Web: fix pagination in the Jobs route [`#2655`](https://github.com/MarquezProject/marquez/pull/2655) [@merobi-hub](https://github.com/merobi-hub) + *Hides job pagination in the case of no jobs.* +* Web: fix empty search experience [`#2679`](https://github.com/MarquezProject/marquez/pull/2679) [@phixMe](https://github.com/phixMe) + *Use of the previous search value was resulting in a bad request for the first character of a search.* + +### Removed: +* Client/Java: remove maven-archiver dependency from the Java client [`#2695`](https://github.com/MarquezProject/marquez/pull/2695) [@davidjgoss](https://github.com/davidjgoss) + *Removes a dependency from `build.gradle` that was bringing some transitive vulnerabilities.* ## [0.42.0](https://github.com/MarquezProject/marquez/compare/0.41.0...0.42.0) - 2023-10-17 ### Added diff --git a/dev/get_changes.py b/dev/get_changes.py index e69d9ab006..9b3c10b004 100755 --- a/dev/get_changes.py +++ b/dev/get_changes.py @@ -1,116 +1,128 @@ -#!/bin/bash +#!/usr/bin/env python3 # # Copyright 2018-2023 contributors to the Marquez project # SPDX-License-Identifier: Apache-2.0 -from github import Github -import rich_click as click from datetime import date from typing import TYPE_CHECKING + +import rich_click as click +from github import Github + if TYPE_CHECKING: from github.PullRequest import PullRequest -class GetChanges: +class GetChanges: def __init__(self, github_token: str, previous: str, current: str, path: str): self.github_token = github_token self.previous = previous self.current = current self.path = path self.pulls: list[PullRequest] = [] - self.rel_title_str: str = '' + self.rel_title_str: str = "" self.text: list[str] = [] self.new_contributors: dict[str:str] = {} def get_pulls(self): - print('Working on it...') + print("Working on it...") g = Github(self.github_token) repo = g.get_repo("MarquezProject/marquez") prev_date = repo.get_release(self.previous).created_at commits = repo.get_commits(since=prev_date) self.pulls = [pull for commit in commits for pull in commit.get_pulls()] - + def write_title(self): - self.rel_title_str = f'## [{self.current}](https://github.com/MarquezProject/marquez/compare/{self.previous}...{self.current}) - {date.today()}' - + self.rel_title_str = f"## [{self.current}](https://github.com/MarquezProject/marquez/compare/{self.previous}...{self.current}) - {date.today()}" # noqa: E501 + def describe_changes(self): for pull in self.pulls: - """ Assembles change description with PR and user URLs """ entry = [] - if pull.user.login != 'dependabot[bot]': + if pull.user.login != "dependabot[bot]": labels = [] for label in pull.labels: - if label.name != 'documentation': + if label.name != "documentation": labels.append(label.name) - change_str = f'* **{labels[0]}: {pull.title}** [`#{pull.number}`]({pull.html_url}) [@{pull.user.login}]({pull.user.html_url}) ' - + try: + change_str = f"* **{labels[0]}: {pull.title}** [`#{pull.number}`]({pull.html_url}) [@{pull.user.login}]({pull.user.html_url}) " # noqa: E501 + except Exception: + continue """ Extracts one-line description if present """ - beg = pull.body.find('One-line summary:') + 18 - if beg == 17: - change_descrip_str = ' **' - else: - test = pull.body.find('### Checklist') - if test == -1: - end = beg + 75 + try: + beg = pull.body.find("One-line summary:") + 18 + if beg == 17: # noqa: PLR2004 + change_descrip_str = " **" else: - end = test - 1 - descrip = pull.body[beg:end].split() - descrip_str = ' '.join(descrip) - change_descrip_str = f' *{descrip_str}*' - - entry.append(change_str + '\n') - entry.append(change_descrip_str + '\n') + test = pull.body.find("### Checklist") + end = beg + 75 if test == -1 else test - 1 + descrip = pull.body[beg:end].split() + descrip_str = " ".join(descrip) + change_descrip_str = f" *{descrip_str}*" + except Exception: + continue + + """ Checks for new contributor """ + self.check_new_contributor(pull) + + entry.append(change_str + "\n") + entry.append(change_descrip_str + "\n") self.text.append(entry) - def get_new_contributors(self): - for pull in self.pulls: - comments = pull.get_issue_comments() - for comment in comments: - if 'Thanks for opening your' in comment.body: - self.new_contributors[pull.user.login] = pull.user.url + def check_new_contributor(self, pull): + comments = pull.get_issue_comments() + for comment in comments: + if "Thanks for opening your" in comment.body: + self.new_contributors[pull.user.login] = pull.user.url + + def print_new_contributors(self): if self.new_contributors: - print('New contributors:') + print("New contributors:") for k, v in self.new_contributors.items(): - print(f'@{k}: {v}') + print(f"@{k}: {v}") else: - print('Note: no new contributors were found.') + print("Note: no new contributors were identified.") def update_changelog(self): - f = open('changes.txt', 'w+') - f = open('changes.txt', 'a') - f.write(self.rel_title_str + '\n') - for entry in self.text: - for line in entry: - f.write(line) - f.close() - - with open('changes.txt', 'r+') as f: + with open("changes.txt", "a") as f: + f.write(self.rel_title_str + "\n") + for entry in self.text: + for line in entry: + f.write(line) + f.close() + + with open("changes.txt", "r+") as f: new_changes = f.read() - with open(self.path, 'r') as contents: + with open(self.path) as contents: save = contents.read() - with open(self.path, 'w') as contents: + with open(self.path, "w") as contents: contents.write(new_changes) - with open(self.path, 'a') as contents: + with open(self.path, "a") as contents: contents.write(save) + @click.command() @click.option( - '--github_token', type=str, default='' + "--github_token", + type=str, + default="", ) @click.option( - "--previous", type=str, default='' + "--previous", + type=str, + default="", ) @click.option( - "--current", type=str, default='' + "--current", + type=str, + default="", ) @click.option( - "--path", - type=str, - default='', - help='absolute path to changelog', + "--path", + type=str, + default="../marquez/CHANGELOG.md", + help="path to changelog", ) - def main( github_token: str, previous: str, @@ -118,18 +130,18 @@ def main( path: str, ): c = GetChanges( - github_token=github_token, - previous=previous, - current=current, - path=path + github_token=github_token, + previous=previous, + current=current, + path=path, ) c.get_pulls() c.describe_changes() c.write_title() c.update_changelog() - c.get_new_contributors() - print('...done!') + c.print_new_contributors() + print("...done!") + if __name__ == "__main__": main() -