Skip to content

Commit

Permalink
Bump version to 0.5.10.7 and fix __drop_duplicates__ method.
Browse files Browse the repository at this point in the history
Updated project version in setup.cfg, pyproject.toml, and __init__.py files. Fixed a bug in the __drop_duplicates__ method by using a copy of the contacts list and handling potential ValueError exceptions during removal.
  • Loading branch information
pnearing committed Sep 14, 2024
1 parent 01439fe commit 85e369f
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ build-backend = "setuptools.build_meta"

[project]
name = "SignalCliAPi"
version = "0.5.10.6"
version = "0.5.10.7"
authors = [
{ name="Peter Nearing", email="[email protected]" }
]
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = SignalCliApi
version = 0.5.10.6
version = 0.5.10.7
author = Peter Nearing
author_email = [email protected]
description = A python interface to the signal-cli found at https://github.com/AsamK/signal-cli
Expand Down
2 changes: 1 addition & 1 deletion src/signal_cli_api/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
File: __init__.py
Description: A python3 interface to signal-cli.
"""
__version__: str = '0.5.10.6'
__version__: str = '0.5.10.7'
__author__: str = 'Peter Nearing'
__email__: str = '[email protected]'

Expand Down
7 changes: 5 additions & 2 deletions src/signal_cli_api/signal_contacts.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,9 +131,12 @@ def __init__(self,
def __drop_duplicates__(self):
orig_contacts = self._contacts.copy()
for orig_contact in orig_contacts:
for contact in orig_contacts:
for contact in self._contacts.copy():
if contact == orig_contact:
self._contacts.remove(contact)
try:
self._contacts.remove(contact)
except ValueError:
pass



Expand Down

0 comments on commit 85e369f

Please sign in to comment.