Open pjsaravanan opened 1 month ago
Dear Saravanan,
Thank you for showing interest in Breeze API.
Generate session API is working fine now, please check.
If you still face any issue, please let us know.
[E29CF836] Thanks & Regards, Akash Sapkal, Team Breeze API, ICICI Securities
From: Saravanan Padmanaban @.> Sent: 11 October 2024 07:54 To: Idirect-Tech/Breeze-Python-SDK @.> Cc: Subscribed @.***> Subject: [Idirect-Tech/Breeze-Python-SDK] Issue with JSON format while GENERATING SESSION (Issue #150)
CAUTION: This email originated from outside the organization! Do not click links, open attachments or reply, unless you recognize the sender's email address! Use 'Report suspicious Email' button in the toolbar to report Phishing mails. Beware!
May I know why all of a sudden I am getting the JSON error while generating session
secret_key = "....." token="...." cn.generate_session(secret_key, token ) Traceback (most recent call last): File "F:\Program Files\Python311\dashapp\Lib\site-packages\requests\models.py", line 974, in json return complexjson.loads(self.text, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "F:\Program Files\Python311\Lib\jsoninit.py", line 346, in loads return _default_decoder.decode(s) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "F:\Program Files\Python311\Lib\json\decoder.py", line 337, in decode obj, end = self.raw_decode(s, idx=_w(s, 0).end()) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "F:\Program Files\Python311\Lib\json\decoder.py", line 355, in raw_decode raise JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "F:\Program Files\Python311\dashapp\Lib\site-packages\breeze_connect\breeze_connect.py", line 797, in api_util json_data = response.json() ^^^^^^^^^^^^^^^ File "F:\Program Files\Python311\dashapp\Lib\site-packages\requests\models.py", line 978, in json raise RequestsJSONDecodeError(e.msg, e.doc, e.pos) requests.exceptions.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "", line 1, in File "F:\Program Files\Python311\dashapp\Lib\site-packages\breeze_connect\breeze_connect.py", line 858, in generate_session self.api_util() File "F:\Program Files\Python311\dashapp\Lib\site-packages\breeze_connect\breeze_connect.py", line 816, in api_util raise Exception("Invalid JSON format in API response") Exception: Invalid JSON format in API response
— Reply to this email directly, view it on GitHubhttps://github.com/Idirect-Tech/Breeze-Python-SDK/issues/150, or unsubscribehttps://github.com/notifications/unsubscribe-auth/A3TQZ4Z5AUYWGAQZYUFH6MDZ24ZGXAVCNFSM6AAAAABPX7SBW6VHI2DSMVQWIX3LMV43ASLTON2WKOZSGU4DAMRWGM2DGOI. You are receiving this because you are subscribed to this thread.Message ID: @.***>
Print this mail only if absolutely necessary. Save Paper. Save Trees." "The information contained in this e-mail and any attachments to this message are intended for the exclusive use of the intended recipient and may contain proprietary, confidential or legally privileged information. If you are not the intended recipient, please note that you are not authorised to disseminate, distribute or copy this e-mail or any parts of it or act upon/rely on the contents of this e-mail in any manner. Please notify the sender immediately by e-mail and destroy all copies of this e-mail and any attachments. Please also note that ICICI Bank or its subsidiaries and associated companies, (collectively "ICICI Group"), are unable to exercise control or ensure the integrity of/over the contents of the information contained in e-mail transmissions and that any views expressed in this e-mail are not endorsed by/binding on the ICICI Group unless the sender does so expressly with due authority of ICICI Group. Before opening any attachments please check them for viruses and defects and please note that ICICI Group accepts no liability or responsibility for any damage caused by any virus that may be transmitted by this email. Any unauthorized use of this email or any attachment(s) may be treated as infringement of right(s) including right of privacy under the applicable laws of India including Information and Technology Act, 2000. Thank you for your cooperation. Regulatory Disclosures are available on https://www.icicisecurities.com (for institutional business) and www.icicidirect.com (for retail business).
May I know why all of a sudden I am getting the JSON error while generating session
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "F:\Program Files\Python311\dashapp\Lib\site-packages\breeze_connect\breeze_connect.py", line 797, in api_util json_data = response.json() ^^^^^^^^^^^^^^^ File "F:\Program Files\Python311\dashapp\Lib\site-packages\requests\models.py", line 978, in json raise RequestsJSONDecodeError(e.msg, e.doc, e.pos) requests.exceptions.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "", line 1, in
File "F:\Program Files\Python311\dashapp\Lib\site-packages\breeze_connect\breeze_connect.py", line 858, in generate_session
self.api_util()
File "F:\Program Files\Python311\dashapp\Lib\site-packages\breeze_connect\breeze_connect.py", line 816, in api_util
raise Exception("Invalid JSON format in API response")
Exception: Invalid JSON format in API response