FIx issue #464 corrupt log file by barry-scott · Pull Request #469 · gitpython-developers/GitPython
Repository navigation
FIx issue #464 corrupt log file - #469
Merged
Byron merged 9 commits into gitpython-developers:master from barry-scott:master Aug 2, 2016
Merged
FIx issue #464 corrupt log file #469 Byron merged 9 commits into gitpython-developers:master from barry-scott:master
Conversation
barry-scott commented Jun 13, 2016
Copy link Copy Markdown
Contributor
Must only append the first line of the commit to the log
Otherwise the log file is not parsable by GitPython.
Fix corruption of the ref logs file
e0eafc4
It must only have the first line of the commit messages, not the while multiple line log.
fix flake8 found problems
a7f403b
Byron
added
the
waiting for feedback
label
Jun 14, 2016
Byron
added this to the
v2.0.6 - Bugfixes milestone
Jun 14, 2016
Byron commented Jun 14, 2016
Copy link Copy Markdown
Member
|
Do you think it's possible for you to write a test which goes red if the change is not there ? The current test-suite should be a good starting-point for a fixture-based test. |
barry-scott commented Jun 14, 2016
Copy link Copy Markdown
Contributor
Author
|
Please don't wait for me to write the test. I have a lot of work on my plate at moment. How I detected the bug was:
|
Merge branch 'master' of https://github.com/gitpython-developers/GitP...
b4b5ecc
...ythonByron modified the milestones: v2.0.7 - Bugfixes , v2.0.8 - Bugfixes Jul 17, 2016 barry-scott added 2 commits July 29, 2016 11:33
Merge remote-tracking branch 'upstream/master'
1116ef7
Prevent CMD windows being shown when starting git in a subprocess.
0d93908
This fixes a UI problem with using GitPython from a GUI python probgram. Each repo that is opened creates a git cat-file processs and that provess will create a console window with out this change.
barry-scott commented Jul 29, 2016
Copy link Copy Markdown
Contributor
Author
|
I'm not sure how to write the tests you want. Can you point to docs on what is required? |
Outdated
| else: | ||
| creationflags = None | ||
|
|
||
| p = Popen(['ps', '--ppid', str(pid)], stdout=PIPE, creationflags) |
Byron commented Jul 30, 2016
Copy link Copy Markdown
Member
|
Now this PR contains two distinct and independent changes. The most recent one is hard to test, and I'd be fine without one. |
Must pass creationflags as a keywork
d79951f
barry-scott commented Aug 1, 2016
Copy link Copy Markdown
Contributor
Author
|
I fixed the keyword parameter passing. |
creationflags must be set to 0 on non-windows platforms
572ebd6
add test to detect the corrupt log
8bde103
- add a second line to commit messages with the "BAD MESSAGE" text - read in the log and confirm that the seond line is not in the log file
barry-scott commented Aug 1, 2016
Copy link Copy Markdown
Contributor
Author
|
I have added a basic test by changing one of the existing test_repo.py tests. You can see the test fail by undoing the first line fix and running the test. |
fix flake8 problems
d8ef023
Byron
merged commit d8ef023
into
gitpython-developers : master
Aug 2, 2016
Byron commented Aug 2, 2016
Copy link Copy Markdown
Member
|
@barry-scott Thank you, looks very good now ! I am particularly excited about the test, and hope in future you can give test-first development a shot as well. |
barry-scott commented Aug 2, 2016
Copy link Copy Markdown
Contributor
Author
|
To get the test as one patch and the the test + fix as a second you will have to fix the dependency of the tests on master. Use of master means that you do not have a reproducible test. Its inputs depend on what the user did to create there master. I suspect that if you had to create the test data that you use master for you might have found this bugs ages ago. |
USE_SHELL = True not needed since 2.0.8 but still suggested for Windows
#1781
Closed
EliahKagan
mentioned this pull request
Jan 16, 2024
Fix two remaining Windows untrusted search path cases
#1792
Merged
Sign up for free
to join this conversation on GitHub .
Already have an account?
Sign in to comment