Skip to content

Commit

Permalink
Fix link thread logic and bump version to 0.5.8.3
Browse files Browse the repository at this point in the history
Enhance the link thread logic to properly check for cancellation and completion before raising LinkInProgress. Increment version in configuration files to 0.5.8.3 to reflect this update.
  • Loading branch information
pnearing committed Sep 9, 2024
1 parent 265fb5f commit 7f3f9df
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 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.8.2"
version = "0.5.8.3"
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.8.2
version = 0.5.8.3
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.8.2'
__version__: str = '0.5.8.3'
__author__: str = 'Peter Nearing'
__email__: str = '[email protected]'

Expand Down
3 changes: 2 additions & 1 deletion src/signal_cli_api/signal_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -876,7 +876,8 @@ def start_link_thread(self,
:return: None.
"""
if self._link_thread is not None:
raise LinkInProgress()
if not self._link_thread.is_canceled or not self._link_thread.is_complete:
raise LinkInProgress()

self._link_thread = SignalLinkThread(
server_address=self._server_address,
Expand Down

0 comments on commit 7f3f9df

Please sign in to comment.