Closed kloczek closed 3 years ago
Hi @kloczek, it seems like the lint command is failing due to an issue with git not being installed:
lint run-test: commands[0] | pre-commit install
An error has occurred: FatalError: git failed. Is it installed, and are you in a Git repository directory?
Check the log at /home/tkloczko/.cache/pre-commit/pre-commit.log
ERROR: InvocationError for command /home/tkloczko/rpmbuild/BUILD/arrow-0.17.0/.tox/lint/bin/pre-commit install (exited with code 1)
Would you mind taking a look at the pre-commit.log
file to see if there is any extra information regarding this issue?
I just rantox
on my end with success:
____________________________________________________________ summary ____________________________________________________________
SKIPPED: pypy3: InterpreterNotFound: pypy3
py27: commands succeeded
SKIPPED: py35: InterpreterNotFound: python3.5
SKIPPED: py36: InterpreterNotFound: python3.6
SKIPPED: py37: InterpreterNotFound: python3.7
py38: commands succeeded
SKIPPED: py39: InterpreterNotFound: python3.9
lint: commands succeeded
docs: commands succeeded
congratulations :)
Also, mind including information on how you are building arrow? Are you cloning the git repo? Or are you using the version from PyPI?
Feel free to re-open this issue if the errors persists, but I am going to close this for now.
After looking into this more, it seems like you have downloaded the tar from PyPI https://pypi.org/project/arrow/#files and extracted it before running tox. It makes sense that lint
would fail since it uses pre-commit hooks, which do not work outside of a git repository. We should probably enlist a standalone solution for linting outside of a git repo.
I'm sorry that I did not reply sending log but I was a bit busy :/
No problem. Since we rely on pre-commit for linting, it might be best if we just check for the presence of a git repo (e.g. .git
folder), and if we don't find it, just pass the lint command.