Skip to content

Improve IterableList Type #11

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

Closed
Byron opened this issue Dec 1, 2010 · 2 comments
Closed

Improve IterableList Type #11

Byron opened this issue Dec 1, 2010 · 2 comments
Assignees

Comments

@Byron
Copy link
Member

Byron commented Dec 1, 2010

Adjust git.utils.IterableList to be more convenient.

Implement the 'contains' method to allow something like:
"upsteam" in repo.heads

@migurski
Copy link

Ultra-belated 👍 to this, running into bugs like:

>>> 'foo' in r.remotes
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "…/site-packages/git/util.py", line 593, in __contains__
    rval = list.__contains__(self, attr)
  File "…/site-packages/git/remote.py", line 405, in __eq__
    return self.name == other.name
AttributeError: 'str' object has no attribute 'name'

migurski added a commit to codeforamerica/chime that referenced this issue Jun 28, 2014
@Byron Byron modified the milestones: v0.3.2, v0.3.5 - bugfixes Nov 14, 2014
@Byron Byron self-assigned this Jan 14, 2015
@Byron
Copy link
Member Author

Byron commented Jan 14, 2015

It seems this one has been fixed quite a while ago.

@Byron Byron closed this as completed Jan 14, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants