Skip to content

Fix 'PushInfo' object has no attribute 'name' #953

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

Merged
merged 2 commits into from
Oct 24, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions git/remote.py
Original file line number Diff line number Diff line change
Expand Up @@ -717,7 +717,7 @@ def _get_push_info(self, proc, progress):
# read the lines manually as it will use carriage returns between the messages
# to override the previous one. This is why we read the bytes manually
progress_handler = progress.new_message_handler()
output = IterableList('name')
output = []

def stdout_handler(line):
try:
Expand Down Expand Up @@ -833,7 +833,7 @@ def push(self, refspec=None, progress=None, **kwargs):
:note: No further progress information is returned after push returns.
:param kwargs: Additional arguments to be passed to git-push
:return:
IterableList(PushInfo, ...) iterable list of PushInfo instances, each
list(PushInfo, ...) list of PushInfo instances, each
one informing about an individual head which had been updated on the remote
side.
If the push contains rejected heads, these will have the PushInfo.ERROR bit set
Expand Down
4 changes: 2 additions & 2 deletions git/test/test_remote.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
GIT_DAEMON_PORT,
assert_raises
)
from git.util import IterableList, rmtree, HIDE_WINDOWS_FREEZE_ERRORS
from git.util import rmtree, HIDE_WINDOWS_FREEZE_ERRORS
import os.path as osp


Expand Down Expand Up @@ -325,7 +325,7 @@ def _assert_push_and_pull(self, remote, rw_repo, remote_repo):
self._commit_random_file(rw_repo)
progress = TestRemoteProgress()
res = remote.push(lhead.reference, progress)
self.assertIsInstance(res, IterableList)
self.assertIsInstance(res, list)
self._do_test_push_result(res, remote)
progress.make_assertion()

Expand Down