From fffb9e3c8a0236f43a201a0f01232a0adccbd685 Mon Sep 17 00:00:00 2001 From: Hrishabh Tiwari <74908943+Hrishabh17@users.noreply.github.com> Date: Fri, 26 Apr 2024 15:05:01 +0530 Subject: [PATCH] Raise Invalid Token error (#27) --- qbosdk/qbosdk.py | 4 ++-- setup.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/qbosdk/qbosdk.py b/qbosdk/qbosdk.py index 15b0291..cdff83a 100644 --- a/qbosdk/qbosdk.py +++ b/qbosdk/qbosdk.py @@ -7,7 +7,7 @@ from future.moves.urllib.parse import urlencode from .exceptions import NotFoundClientError, QuickbooksOnlineSDKError, UnauthorizedClientError,\ - WrongParamsError, InternalServerError + WrongParamsError, InternalServerError, InvalidTokenError from .apis import * @@ -159,7 +159,7 @@ def __get_access_token(self): raise InternalServerError('Internal server error', response.text) else: - raise QuickbooksOnlineSDKError('Error: {0}'.format(response.status_code), response.text) + raise InvalidTokenError('Error: {0}'.format(response.status_code), response.text) def revoke_refresh_token(refresh_token: str, client_id: str, client_secret: str): api_data = { diff --git a/setup.py b/setup.py index 442ccfc..284c18d 100644 --- a/setup.py +++ b/setup.py @@ -8,7 +8,7 @@ setuptools.setup( name='qbosdk', - version='0.17.2', + version='0.17.3', author='Shwetabh Kumar', author_email='shwetabh.kumar@fyle.in', description='Python SDK for accessing Quickbooks Online APIs',