borgbackup / borgbackup/borghash
make api more python3-dict-like
- Dominant language
- Cython
- Stars
- 6
- Forks
- 3
- Avg merge
- 2h 31m
- Merged PRs (30d)
- 6
Description
the current api is not quite like a dictionary, but rather like borgbackup's hashindex api is like.
considering that borgbackup has a wrapper class around borghash classes anyway, we can change borghash api to be more like python3 dict api.
maybe not implement everything, but **name** the frequently used stuff as usual:
- [X] `.iteritems` -> `.items`
- [X] `__init__`: make all special stuff pure kwargs
- [x] `.update`
- also implement `__iter__`, `.keys` and `.values`
Check:
- `collections.abc.Mapping`
- `collections.abc.MutableMapping` https://github.com/python/cpython/blob/3.13/Lib/_collections_abc.py#L924
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.