since Python 3.10 dropped the alias.
Git command argument handling helpers
"""
-import collections
+import collections.abc
class GitArgs(object):
for arg in args:
if isinstance(arg, str):
self._args.append(arg)
- elif isinstance(arg, collections.Iterable):
+ elif isinstance(arg, collections.abc.Iterable):
for i in iter(arg):
self._args.append(str(i))
else:
# <http://www.gnu.org/licenses/>
"""Simple implementation of a doubly linked list"""
-import collections
+import collections.abc
import gbp.log
self._data = None
-class LinkedListIterator(collections.Iterator):
+class LinkedListIterator(collections.abc.Iterator):
"""Iterator for the linked list"""
def __init__(self, obj):
return self.__next__()
-class LinkedList(collections.Iterable):
+class LinkedList(collections.abc.Iterable):
"""Doubly linked list"""
def __init__(self):