-
-
Notifications
You must be signed in to change notification settings - Fork 934
test_index_file_diffing fails with git 2.30.0 #1103
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
Comments
Which gitpython version are you using? |
Cloned just before filing the report:
|
Maybe it's related to the recent change in how diffs work: 69b75e1 (and the two commits before that one). Maybe you could try that with the previous gitpython release to test this idea. It's strange though that there is a difference in |
I don't seem to get the previous tag to work but I've reverted 69b75e1 and the two commits before it, and the test fails the same. |
Thanks, it's good to know the recent modifications didn't cause subtle breakage. self.assertRaises(CheckoutError, index.checkout, "doesnt_exist_ever.txt.that") An assertion to an exception being thrown if a file that doesn't exist is checked out. An exception is indeed thrown, yet it's unhappy. Is it related to Python not liking the exception that is thrown? Because to git it's all the same, it's a process which doesn't exit with 0 which in turn gets handled in Python. |
Were you able to install git 2.30 and reproduce? |
Yes, I can reproduce it, here is the logs:
|
However, the test asserts on the provided context to be correct, which is hard to do in this branch while it's easy to doubt the value of this. Lastly, there seems to be no way to ignore errors in `git` without muting all output, which is in fact parsed. Maybe it's possible to ignore errors while parsing the new kind of error message.
Ah, right, the assertion expects a @mgorny I left some notes in #1104 which might help someone finalize the fix. As the GitCommandError has access to stderr, it should be possible to parse stderr lines and retrieve the necessary information from there. |
The PR has been fixed up to 'make' the test succeed, which also fixes this issue. |
Seems to pass with 2.29.2.
The text was updated successfully, but these errors were encountered: