Skip to content

Commit

Permalink
Merge branch 'master' into renatav/add-dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
renatav authored Aug 17, 2023
2 parents aa6fc17 + a3dcc20 commit 6250b35
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,18 @@ and this project adheres to [Semantic Versioning][semver].
### Added

- Add functions for adding/updating/removing dependencies to/from dependencies.json ([338])

### Changed

- Remove hosts and hosts.json ([330])

### Fixed

- fix commits per repositories function when same target commits are on different branches ([337])
- Add missing `write` flag to `taf targets sign` ([329])

[338]: https://github.com/openlawlibrary/taf/pull/338
[337]: https://github.com/openlawlibrary/taf/pull/337
[330]: https://github.com/openlawlibrary/taf/pull/330
[329]: https://github.com/openlawlibrary/taf/pull/329

Expand Down
9 changes: 6 additions & 3 deletions taf/auth_repo.py
Original file line number Diff line number Diff line change
Expand Up @@ -256,9 +256,12 @@ def sorted_commits_and_branches_per_repositories(
continue
target_branch = target_data.get("branch")
target_commit = target_data.get("commit")
previous_commit = previous_commits.get(target_path)
previous_data = previous_commits.get(target_path)
target_data.setdefault("custom", {})
if previous_commit is None or target_commit != previous_commit:
if (
previous_data is None
or (target_commit, target_branch) != previous_data
):
if custom_fns is not None and target_path in custom_fns:
target_data["custom"].update(
custom_fns[target_path](target_commit)
Expand All @@ -273,7 +276,7 @@ def sorted_commits_and_branches_per_repositories(
"auth_commit": commit,
}
)
previous_commits[target_path] = target_commit
previous_commits[target_path] = (target_commit, target_branch)
self._log_debug(
f"new commits per repositories according to target files: {repositories_commits}"
)
Expand Down

0 comments on commit 6250b35

Please sign in to comment.