Fix usage of file/folder names without suffix in Downloader (#5938)

This commit is contained in:
Jakub Kuczys
2022-12-27 00:39:17 +01:00
committed by GitHub
parent f02491a092
commit e88884edb6
3 changed files with 10 additions and 9 deletions

View File

@@ -84,7 +84,7 @@ class Installable(RepoJSONMixin):
self._location = location
self.repo = repo
self.repo_name = self._location.parent.stem
self.repo_name = self._location.parent.name
self.commit = commit
self.end_user_data_statement: str
@@ -129,7 +129,7 @@ class Installable(RepoJSONMixin):
# noinspection PyBroadException
try:
copy_func(src=str(self._location), dst=str(target_dir / self._location.stem))
copy_func(src=str(self._location), dst=str(target_dir / self._location.name))
except: # noqa: E722
log.exception("Error occurred when copying path: %s", self._location)
return False