superlinear-ai / poetry-cookiecutter

🍪 Poetry Cookiecutter is a modern Cookiecutter template for scaffolding Python packages and apps
GNU Affero General Public License v3.0
252 stars 37 forks source link

An error has occurred: FatalError: git failed. Is it installed, and are you in a Git repository directory? #167

Closed chanansh closed 1 year ago

chanansh commented 1 year ago

added an single method and test.

  1. it seems like build does not happen before test. why are they parallel? (prebuild-->test)
  2. I get an error of missing git.

Can you please explain why there are so many dockers here? There is the runner docker but why there is an internal docker within it?

How can I resolve the error below?

Running with gitlab-runner 15.8.1 (f86890c6) on project-runner GTJx6quu, system ID: r_mq4cgQbAqrZp Resolving secrets 00:00 Preparing the "docker" executor 00:01 Preparing environment 00:01 Running on runner-gtjx6quu-project-79468-concurrent-0 via project-runner... Getting source from Git repository 00:00 Fetching changes with git depth set to 20... Reinitialized existing Git repository in /builds/my_group/project_utils/.git/ Checking out 79f8fd13 as main... Skipping Git submodules setup Restoring cache 00:01 Checking cache for main-protected... No URL provided, cache will not be downloaded from shared cache server. Instead a local version of cache will be extracted. Successfully extracted cache Executing "step_script" stage of the job script 00:01 Using docker image sha256:861047f978ab4193c1f84582550f648fef9e0edc0ece5295c60ab9e8e79b33e5 for my_git_server/my_group/my_project/ci:d6d1b20830ad with digest my_git_server/my_group/my_project/ci@sha256:0af0320593e84eeceb0368b2a6632aad665a09e60cd274431acf3903cf0d7d41 ... $ poe lint Poe => pre-commit run --all-files --color always An error has occurred: FatalError: git failed. Is it installed, and are you in a Git repository directory? Check the log at /home/app/.cache/pre-commit/pre-commit.log Error: Sequence aborted after failed subtask 'lint[0]' Uploading artifacts for failed job 00:01 Uploading artifacts... WARNING: untracked: no files
ERROR: No files to upload
Uploading artifacts... WARNING: reports/mypy.xml: no matching files. Ensure that the artifact path is relative to the working directory (/builds/my_group/project_utils) WARNING: reports/pytest.xml: no matching files. Ensure that the artifact path is relative to the working directory (/builds/my_group/project_utils) ERROR: No files to upload
Uploading artifacts... WARNING: reports/coverage.xml: no matching files. Ensure that the artifact path is relative to the working directory (/builds/my_group/project_utils) ERROR: No files to upload
Cleaning up project directory and file based variables 00:00 ERROR: Job failed: exit code 1

lsorber commented 1 year ago

This is related to #166. I was able to reproduce this as well.

lsorber commented 1 year ago

Hey @chanash, this should be fixed now. Sorry it took a bit to get it merged!