Commit ed2b742c authored by Christophe Benz's avatar Christophe Benz
Browse files

Show current commit for every dataset log message

parent d69d33fe
......@@ -74,14 +74,10 @@ class GitWalker:
self._series_of_dataset_json: dict[DatasetCode, dict[SeriesCode, dict]] = {}
for git_commit_index, (previous_git_commit, git_commit) in enumerate(git_commit_pairs, start=1):
logger.info(
"===== [%d/%d] Importing Git commit %r =====",
git_commit_index,
len(git_commit_pairs),
str(git_commit.hexsha),
)
git_commit_log_stamp = f"{git_commit_index}/{len(git_commit_pairs)} {str(git_commit.hexsha)!r}"
logger.info("===== [%s] Importing Git commit =====", git_commit_log_stamp)
self._import_git_commit(git_commit, previous_git_commit, datasets)
self._import_git_commit(git_commit, previous_git_commit, datasets, git_commit_log_stamp)
# Add modified tables and create commit in Dolt repo
self._git_importer.commit(git_commit)
......@@ -97,6 +93,7 @@ class GitWalker:
git_commit: Commit,
previous_git_commit: Optional[Commit],
datasets: list[DatasetCode],
git_commit_log_stamp: str,
):
git_commit_changes = self._get_git_commit_changes(git_commit, previous_git_commit, datasets)
......@@ -135,7 +132,8 @@ class GitWalker:
):
dataset_tree = git_commit.tree / dataset_code
logger.info(
"----- [%d/%d %r] Importing dataset tree %r",
"----- [%s] (%d/%d %r) Importing dataset tree %r",
git_commit_log_stamp,
dataset_tree_index,
len(git_commit_changes.dataset_trees),
dataset_code,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment