Skip to content

Commit cfda873

Browse files
jsamrokroskar
authored andcommitted
fix: addressed CI problems with git submodules (#783)
* fix: addressed CI problems with git submodules * fix: pin to git2.x * pin to git 3.2
1 parent e1acf60 commit cfda873

File tree

6 files changed

+9
-6
lines changed

6 files changed

+9
-6
lines changed

conftest.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ def project(repository):
159159
"""Create a test project."""
160160
from git import Repo
161161

162-
repo = Repo(repository)
162+
repo = Repo(repository, search_parent_directories=True)
163163
commit = repo.head.commit
164164

165165
os.chdir(repository)
@@ -306,7 +306,10 @@ def old_repository(tmpdir_factory, old_bare_repository):
306306
repo_path = tmpdir_factory.mktemp('repo')
307307
yield {
308308
'repo':
309-
Repo(old_bare_repository['path'].strpath).clone(repo_path.strpath),
309+
Repo(
310+
old_bare_repository['path'].strpath,
311+
search_parent_directories=True
312+
).clone(repo_path.strpath),
310313
'exit_code': old_bare_repository['exit_code']
311314
}
312315
shutil.rmtree(repo_path.strpath)

renku/cli/exception_handler.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,8 @@ def _handle_sentry(self):
136136
from renku.core.commands import get_git_home
137137
from renku.core.models.datasets import Creator
138138

139-
user = Creator.from_git(Repo(get_git_home()))
139+
repo = Repo(get_git_home())
140+
user = Creator.from_git(repo)
140141

141142
scope.user = {'name': user.name, 'email': user.email}
142143

renku/core/commands/graph.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,6 @@ def process_dependencies(self, dependencies, visited=None):
284284
visited.add(processing.commit)
285285

286286
activity = processing.client.process_commit(processing.commit)
287-
288287
if activity is None:
289288
continue
290289

renku/core/management/repository.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,6 @@ def process_commit(self, commit=None, path=None):
180180
from renku.core.models.provenance.activities import Activity
181181

182182
commit = commit or self.repo.head.commit
183-
184183
if len(commit.parents) > 1:
185184
return Activity(commit=commit, client=self)
186185

renku/core/models/provenance/activities.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,7 @@ def paths(self):
183183

184184
for file_ in self.commit.diff(self.commit.parents or NULL_TREE):
185185
path_ = Path(file_.a_path)
186+
186187
is_dataset = self.client.DATASETS in str(path_)
187188
not_refs = LinkReference.REFS not in str(path_)
188189
does_not_exists = not path_.exists()

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@
8080
'cwltool==1.0.20181012180214',
8181
'environ_config>=18.2.0',
8282
'filelock>=3.0.0',
83-
'gitpython>=2.1.8',
83+
'gitpython==3.0.3',
8484
'patool>=1.12',
8585
'psutil>=5.4.7',
8686
'pyasn1>=0.4.5',

0 commit comments

Comments
 (0)