Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upReading progress of Git operation using GitPython stuck (or not printing) #871
Comments
Try an older version of git (v2.20.0) as in v2.21.0 of git they changed the output strings to allow for localization, and that's caused at least one bug, let's see if it caused others... |
I switched to both the default macOS Git I'll create stripped down script to check if I can reproduce it reliably. |
Since I switched to the older Git version and later on reinstalled Git I solved the second problem of the progress not being logged though and have a proposal for an implementation-, or at least documentation-change: If the git process finishes quickly, the This way we do not break existing implementations and keep the progress handling in one place. Yes, I could check if my Also a note within the documentation for $ git reset --hard @~100
$ git remote remove origin
$ git reflog expire --expire=now --all && git gc --prune=now --aggressive
$ git remote add origin <url> |
Perhaps update() should always be called at least once? |
I proposed a pull request in which I adapt the behaviour in a way, that |
This reverts commit 687c8f0. Causes https://travis-ci.org/gitpython-developers/GitPython/jobs/561359367 Reopen #871
…to date" #871""" This reverts commit 9b628dc. Definitely doesn't work https://travis-ci.org/gitpython-developers/GitPython/builds/561361507
I'm trying to access the progress of time consuming Git operations using GitPython. I tried the sample solution taken from the official documentation, and also tried passing in a method following the exact signature of the update method below. Everytime I call
fetch()
,push()
,pull()
with the parameterprogress=<anything>
, the programm is stuck and theupdate
method does not get called. If I call those operations without setting theprogress
parameter, it works flawlessly.$ git --version
is 2.21.0sys.stdout.flush()
afterprint()
does not help eitherassert
to assure my repo objects are available and in the expected stateProgressPrinter()
yields notNone
RemoteProgress
and also the implementation (line 815) ofpush()
and do not see a reason, why it would not continue executionProgressPrinter
instance and pass the assigned variable, the programm is not stuck anymore. Yet theupdate()
method does not get called and no progress is printed:Core of my implementation:
And later on:
Any recommendations on how to investigate this problem furthermore? I've been debugging this for several days now and feel like I am missing something.