diff --git a/.github/workflows/test_deploy.yml b/.github/workflows/test_deploy.yml index 5a57b63c98..b08356756c 100644 --- a/.github/workflows/test_deploy.yml +++ b/.github/workflows/test_deploy.yml @@ -628,7 +628,7 @@ jobs: publish-chart: runs-on: ubuntu-latest - needs: [docs-linux, test-linux-cli, test-linux-core, test-linux-service, test-macos-cli, test-macos-core, test-macos-service, test-linux-integration, test-macos-integration] + needs: [docs-linux, test-linux-cli, test-linux-core, test-linux-service, test-macos-cli, test-macos-core, test-macos-service, test-linux-integration, test-linux-integration-service, test-macos-integration] if: startsWith(github.ref, 'refs/tags/') steps: - uses: actions/checkout@v2 @@ -655,7 +655,7 @@ jobs: coveralls-final: name: Aggregate coveralls data - needs: [test-linux-cli, test-linux-core, test-linux-service, test-linux-api, test-linux-integration] + needs: [test-linux-cli, test-linux-core, test-linux-service, test-linux-api, test-linux-integration, test-linux-integration-service] runs-on: ubuntu-latest permissions: contents: read diff --git a/renku/core/management/migrations/m_0005__2_cwl.py b/renku/core/management/migrations/m_0005__2_cwl.py index 058bde1f08..d2c44b41fd 100644 --- a/renku/core/management/migrations/m_0005__2_cwl.py +++ b/renku/core/management/migrations/m_0005__2_cwl.py @@ -475,7 +475,7 @@ def find_previous_commit(self, path, revision="HEAD"): def find_from_client(path, revision): try: - return self.client.repository.get_previous_commit(paths=path, revision=revision, full_history=True) + return self.client.repository.get_previous_commit(path=path, revision=revision, full_history=True) except errors.GitCommitNotFoundError: communication.warn(f"Cannot find previous commit for {path} from {str(revision)}") return revision diff --git a/renku/core/management/migrations/m_0009__new_metadata_storage.py b/renku/core/management/migrations/m_0009__new_metadata_storage.py index 946e0340a9..32db3b2d8e 100644 --- a/renku/core/management/migrations/m_0009__new_metadata_storage.py +++ b/renku/core/management/migrations/m_0009__new_metadata_storage.py @@ -506,7 +506,7 @@ def _convert_invalidated_entity(entity: old_schema.Entity, client) -> Optional[E assert not isinstance(entity, old_schema.Collection), f"Collection passed as invalidated: {entity._id}" commit_sha = _extract_commit_sha(entity_id=entity._id) - commit = client.repository.get_previous_commit(revision=commit_sha, paths=entity.path) + commit = client.repository.get_previous_commit(revision=commit_sha, path=entity.path) revision = commit.hexsha checksum = client.repository.get_object_hash(revision=revision, path=entity.path) if not checksum: diff --git a/renku/core/metadata/repository.py b/renku/core/metadata/repository.py index 1005c6a5bd..c710a890a9 100644 --- a/renku/core/metadata/repository.py +++ b/renku/core/metadata/repository.py @@ -286,12 +286,16 @@ def get_attributes(self, *paths: Union[Path, str]) -> Dict[str, Dict[str, str]]: return attributes - def get_previous_commit(self, path: Union[Path, str], revision: Union["Commit", str] = None) -> Optional["Commit"]: + def get_previous_commit( + self, path: Union[Path, str], revision: Union["Commit", str] = None, full_history: bool = False + ) -> Optional["Commit"]: """Return a previous commit for a given path starting from ``revision``.""" revision = revision or "HEAD" assert isinstance(revision, (Commit, str)), f"'revision' must be Commit/str not '{type(revision)}'" - commit = _find_previous_commit_helper(repository=self, path=path, revision=str(revision)) + commit = _find_previous_commit_helper( + repository=self, path=path, revision=str(revision), full_history=full_history + ) if not commit: raise errors.GitCommitNotFoundError(f"Cannot find previous commit for '{path}' from '{revision}'") return commit diff --git a/setup.py b/setup.py index 156bd5107f..993e7f2edb 100644 --- a/setup.py +++ b/setup.py @@ -91,6 +91,7 @@ def run(self): "black==21.9b0", "check-manifest>=0.37,<0.47", "coverage>=4.5.3,<5.6", + "cwl-utils>=0.12", "fakeredis>=1.4.1,<1.6.2", "flake8>=3.8,<3.10", "flaky==3.7.0", @@ -165,7 +166,6 @@ def run(self): "cryptography>=3.4.1,<3.5", "cwlgen>=0.4.0,<=0.4.2", "cwltool==3.1.20210922203925", - "cwl-utils>=0.10", "deepmerge==0.3.0", "environ_config>=18.2.0,<21.3.0", "filelock>=3.0.0,<=3.0.12", diff --git a/tests/cli/test_datasets.py b/tests/cli/test_datasets.py index 3be552665b..bad935c7e2 100644 --- a/tests/cli/test_datasets.py +++ b/tests/cli/test_datasets.py @@ -881,7 +881,7 @@ def test_datasets_ls_files_correct_commit(runner, client, directory_tree): """Test ls-files shows the size stored in git and not the current file size.""" assert 0 == runner.invoke(cli, ["dataset", "add", "my-dataset", "-c", str(directory_tree / "file1")]).exit_code - commit = client.repository.get_previous_commit(paths=client.path / DATA_DIR / "my-dataset" / "file1") + commit = client.repository.get_previous_commit(path=client.path / DATA_DIR / "my-dataset" / "file1") # check include / exclude filters result = runner.invoke(cli, ["dataset", "ls-files", "--columns=commit,path"]) diff --git a/tests/cli/test_workflow.py b/tests/cli/test_workflow.py index 9812f4bf38..379fe6d9e4 100644 --- a/tests/cli/test_workflow.py +++ b/tests/cli/test_workflow.py @@ -26,7 +26,7 @@ import pexpect import pyte import pytest -from cwl_utils import parser_v1_2 as cwlgen +from cwl_utils.parser import cwl_v1_2 as cwlgen from renku.cli import cli from renku.core.metadata.database import Database diff --git a/tests/data/old-workflows-complicated-v0.10.3.git.tar.gz b/tests/data/old-workflows-complicated-v0.10.3.git.tar.gz index 6f3a27ff00..c61ec306ce 100644 Binary files a/tests/data/old-workflows-complicated-v0.10.3.git.tar.gz and b/tests/data/old-workflows-complicated-v0.10.3.git.tar.gz differ