Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

git command - fatal: destination path, repo already exists and is not an empty directory #95

Open
valeriocos opened this issue May 24, 2020 · 1 comment

Comments

@valeriocos
Copy link
Member

When executing the docker 3p container, the error below appears after the second execution (included).

2020-05-23 20:59:34,981 - grimoire_elk.elk - ERROR - Error feeding raw from cocom (https://github.com/chaoss/grimoirelab-toolkit): git command - fatal: destination path '/home/grimoirelab/.graal/repositories/https://github.com/chaoss/grimoirelab-toolkit-git' already exists and is not an empty directory.
Traceback (most recent call last):
  File "/usr/local/lib/python3.5/dist-packages/grimoire_elk/elk.py", line 228, in feed_backend
    ocean_backend.feed(**params)
  File "/usr/local/lib/python3.5/dist-packages/grimoire_elk/raw/elastic.py", line 230, in feed
    self.feed_items(items)
  File "/usr/local/lib/python3.5/dist-packages/grimoire_elk/raw/elastic.py", line 246, in feed_items
    for item in items:
  File "/usr/local/lib/python3.5/dist-packages/perceval/backend.py", line 215, in fetch
    for item in self.fetch_items(category, **kwargs):
  File "/usr/local/lib/python3.5/dist-packages/graal/graal.py", line 166, in fetch_items
    self.graalRepo = self.__create_graal_repository()
  File "/usr/local/lib/python3.5/dist-packages/graal/graal.py", line 251, in __create_graal_repository
    repo = GraalRepository.clone(self.uri, self.gitpath)
  File "/usr/local/lib/python3.5/dist-packages/perceval/backends/core/git.py", line 826, in clone
    cls._exec(cmd, env=env)
  File "/usr/local/lib/python3.5/dist-packages/perceval/backends/core/git.py", line 1331, in _exec
    raise RepositoryError(cause=cause)
perceval.errors.RepositoryError: git command - fatal: destination path '/home/grimoirelab/.graal/repositories/https://github.com/chaoss/grimoirelab-toolkit-git' already exists and is not an empty directory.
@vinhbt
Copy link

vinhbt commented Apr 15, 2024

In file: grimoirelab-graal/graal/graal.py, function def fetch_items(self, category, **kwargs):
When exception occur logger.error("Analysis failed at %s" % commit['commit']) => graalRepo not be prune so I think should be add self.graalRepo.prune() before raise exception.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants