Skip to content

Commit

Permalink
Add TimeoutException and update some dev dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
ylabonte committed May 9, 2024
1 parent abe62be commit 739eae1
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 7 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,8 @@ output), there is a really simple way to support me:

## Release Notes

### In progress...
### v1.3.1 (2024-05-09)
* Add dedicated `api.TimeoutException` to raise for connection timeouts.
* Add dependabot with `versioning-strategy: "increase"` and an auto-merge workflow for automated updates on the github
`main` branch.
* Add code scanning (CodeQL) workflow.
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "hatchling.build"

[project]
name = "proconip"
version = "1.3.0"
version = "1.3.1"
authors = [
{ name="Yannic Labonte", email="[email protected]" },
]
Expand Down
5 changes: 3 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
black >= 24.1
setuptools >= 69.1
black==24.4.2
setuptools==69.5.1
hatchling==1.24.2
6 changes: 5 additions & 1 deletion src/proconip/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ async def async_start_dosage(
response.raise_for_status()
return await response.text()
except asyncio.TimeoutError as exception:
raise ProconipApiException(
raise TimeoutException(
"Timeout error fetching data",
) from exception
except (ClientError, socket.gaierror) as exception:
Expand Down Expand Up @@ -317,3 +317,7 @@ class BadCredentialsException(ProconipApiException):

class BadStatusCodeException(ProconipApiException):
"""Exception to raise when we get an unknown response code."""


class TimeoutException(ProconipApiException):
"""Exception to raise when the connection times out."""
2 changes: 1 addition & 1 deletion src/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@
"yarl>=1.9",
]

setup(name="proconip", version="1.3.0", packages=find_packages())
setup(name="proconip", version="1.3.1", packages=find_packages())
2 changes: 1 addition & 1 deletion tests/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
aiohttp >= 3.9
aiohttp==3.9.5
async-timeout >= 4.0
yarl >= 1.9
--editable src

0 comments on commit 739eae1

Please sign in to comment.