Idirect-Tech / Breeze-Python-SDK

The official Python client library for the ICICI Securities trading APIs
MIT License
53 stars 28 forks source link

11750PE Midcap nifty missing in StockScriptNew https://traderweb.icicidirect.com/Content/File/txtFile/ScripFile/StockScriptNew.csv #102

Open mavink opened 1 month ago

mavink commented 1 month ago

Boss, whats going on??? There is no entry for 11750 pe in the file, though 11750ce is there. How is this file generated??? How can you allow errors like this? Its missing for all expiry dates. Whole day wasted today tracking down your stupid mistake. Dont you have any verification process when you generate this file??? Please get serious.

Idirect-Tech commented 1 month ago

Dear Client,

Requested to elaborate the issue.

Could you please mention which file you are using so that we can investigate the same.

[E29CF836]

Thanks & Regards,

Amrit Mohanty,

API & Algo Products,

Derivatives, EPG

ICICIdirect


From: mavink @.> Sent: Monday, May 27, 2024 3:30 PM To: Idirect-Tech/Breeze-Python-SDK @.> Cc: Subscribed @.***> Subject: [Idirect-Tech/Breeze-Python-SDK] 11750PE Midcap nifty missing in StockScriptNew https://traderweb.icicidirect.com/Content/File/txtFile/ScripFile/StockScriptNew.csv (Issue #102)

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!

Boss, whats going on??? There is no entry for 11750 pe in the file, though 11750ce is there. How is this file generated??? How can you allow errors like this? Its missing for all expiry dates. Whole day wasted today tracking down your stupid mistake. Dont you have any verification process when you generate this file??? Please get serious.

— Reply to this email directly, view it on GitHubhttps://github.com/Idirect-Tech/Breeze-Python-SDK/issues/102, or unsubscribehttps://github.com/notifications/unsubscribe-auth/A3TQZ43QXI4KRJKU46NSNZDZEL74VAVCNFSM6AAAAABIK4DDK6VHI2DSMVQWIX3LMV43ASLTON2WKOZSGMYTQNZWGM3TKMQ. 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).

mavink commented 1 month ago

While trying to subscribe to 11750 NIFSEL PE 27th May

breeze.subscribe_feeds(exchange_code=C.option_exchange_code, stock_code=C.stock_code, product_type="options", expiry_date=C.options_expiry_date, strike_price="11750", right="Put",get_exchange_quotes=True, get_market_depth=False)

the following error kept on occuring today

`breeze_connect.py", line 359, in subscribe_feeds exchange_quotes_token, market_depth_token = self.get_stock_token_value(exchange_code=exchange_code, stock_code=stock_code, product_type=product_type, expiry_date=expiry_date, strike_price=strike_price, right=right, get_exchange_quotes=get_exchange_quotes, get_market_depth=get_market_depth) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "breeze_connect.py", line 320, in get_stock_token_value exchange_quotes_token_value = exchange_code_name + "1!" + token_value


TypeError: can only concatenate str (not "bool") to str`
mavink commented 1 month ago

Because the csv file at https://traderweb.icicidirect.com/Content/File/txtFile/ScripFile/StockScriptNew.csv which is used to fetch the stock token value did not have the relevant entry for 11750 NIFSEL PE 27th May

WhatsApp Image 2024-05-27 at 15 22 55_2d0dfb9e

There is no 11750 NIFSEL PE 27th May in the csv file

mavink commented 1 month ago

#Stock Script Code Download Link STOCK_SCRIPT_CSV_URL = "https://traderweb.icicidirect.com/Content/File/txtFile/ScripFile/StockScriptNew.csv"

The list of tokens is downloaded from here in config.py

Idirect-Tech commented 1 month ago

Dear Client,

The expired contracts would not be there inside the stock script.

Use 4.1! for subscribing an instrument using a stock token.

Please find the below code snippet to subscribe single as well as multiple instruments using stock token.

import time from breeze_connect import BreezeConnect from datetime import datetime, timedelta key_api = "" key_secret = "" key_session = "" breeze = BreezeConnect(api_key=key_api) breeze.generate_session(api_secret=key_secret, session_token=key_session)

Connect to websocket(it will connect to tick-by-tick data server)

breeze.ws_connect()

Callback to receive ticks.

def on_ticks(ticks): data.append(ticks) print("Ticks: {}".format(ticks))

Assign the callbacks.

breeze.on_ticks = on_ticks

Please find the below link to get the stock tokens.

https://traderweb.icicidirect.com/Content/File/txtFile/ScripFile/StockScriptNew.csv

Sample Code for Subscribing Live Feeds for Multiple Stocks:

breeze.get_names(exchange_code = 'NSE',stock_code = 'TATASTEEL')["isec_token_level1"]

Output: "4.1!3499"

breeze.get_names(exchange_code = 'NSE',stock_code = 'RELIANCE')["isec_token_level1"]

Output : "4.1!2885"

breeze.subscribe_feeds(stock_token=['4.1!3499','4.1!2885'])

[E29CF836]

Thanks & Regards,

Amrit Mohanty,

API & Algo Products,

Derivatives, EPG

ICICIdirect


From: mavink @.> Sent: Monday, May 27, 2024 6:00 PM To: Idirect-Tech/Breeze-Python-SDK @.> Cc: BREEZEAPI @.>; Comment @.> Subject: Re: [Idirect-Tech/Breeze-Python-SDK] 11750PE Midcap nifty missing in StockScriptNew https://traderweb.icicidirect.com/Content/File/txtFile/ScripFile/StockScriptNew.csv (Issue #102)

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!

Stock Script Code Download Link STOCK_SCRIPT_CSV_URL = "https://traderweb.icicidirect.com/Content/File/txtFile/ScripFile/StockScriptNew.csv"

The list of tokens is downloaded from here in config.py

— Reply to this email directly, view it on GitHubhttps://github.com/Idirect-Tech/Breeze-Python-SDK/issues/102#issuecomment-2133382893, or unsubscribehttps://github.com/notifications/unsubscribe-auth/A3TQZ46OV2R7OMT5TODLU2DZEMRNZAVCNFSM6AAAAABIK4DDK6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMZTGM4DEOBZGM. You are receiving this because you commented.

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).

mavink commented 1 month ago

Dear Amit, It's okay if you don't want to acknowledge the issue that's fine. You can behave as though there was no error in your side. I think you are getting paid only to send useless replies.

The issue was raised on 27th May. On the same day of MidCap SELECT expiry.

Further as you can see in the screen shot even 3rd June 11750 PE NIFSEL was missing from the csv file.

But if you continue to make errors like these customers will continue to migrate to other better platforms.

Idirect-Tech commented 1 month ago

Dear Client,

11750 PE MIDCAP Select for 3rd June is already there.

Please find the attached screenshot for the same.

[cid:d92cda6c-83be-43dc-a398-300d19989724]

[E29CF836]

Thanks & Regards,

Amrit Mohanty,

API & Algo Products,

Derivatives, EPG

ICICIdirect


From: mavink @.> Sent: Wednesday, May 29, 2024 10:41 AM To: Idirect-Tech/Breeze-Python-SDK @.> Cc: BREEZEAPI @.>; Comment @.> Subject: Re: [Idirect-Tech/Breeze-Python-SDK] 11750PE Midcap nifty missing in StockScriptNew https://traderweb.icicidirect.com/Content/File/txtFile/ScripFile/StockScriptNew.csv (Issue #102)

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!

Dear Amit, It's okay if you don't want to acknowledge the issue that's fine. You can behave as though there was no error in your side. I think you are getting paid only to send useless replies.

The issue was raised on 27th May. On the same day of MidCap SELECT expiry.

Further as you can see in the screen shot even 3rd June 11750 PE NIFSEL was missing from the csv file.

But if you continue to make errors like these customers will continue to migrate to other better platforms.

— Reply to this email directly, view it on GitHubhttps://github.com/Idirect-Tech/Breeze-Python-SDK/issues/102#issuecomment-2136524748, or unsubscribehttps://github.com/notifications/unsubscribe-auth/A3TQZ424VUCK7SOSZLV2YFTZEVPPRAVCNFSM6AAAAABIK4DDK6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMZWGUZDINZUHA. You are receiving this because you commented.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).

mavink commented 1 month ago

It was not there on 27th of May. Kindly check the uploaded file of 27th May. Kindly upload the csv file of 27th May. Then we can discuss further.

mavink commented 1 month ago

Dear Client, 11750 PE MIDCAP Select for 3rd June is already there. Please find the attached screenshot for the same. [cid:d92cda6c-83be-43dc-a398-300d19989724] [E29CF836] Thanks & Regards, Amrit Mohanty, API & Algo Products, Derivatives, EPG ICICIdirect ____ From: mavink @.> Sent: Wednesday, May 29, 2024 10:41 AM To: Idirect-Tech/Breeze-Python-SDK @.> Cc: BREEZEAPI @.>; Comment @.> Subject: Re: [Idirect-Tech/Breeze-Python-SDK] 11750PE Midcap nifty missing in StockScriptNew https://traderweb.icicidirect.com/Content/File/txtFile/ScripFile/StockScriptNew.csv (Issue #102) 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! Dear Amit, It's okay if you don't want to acknowledge the issue that's fine. You can behave as though there was no error in your side. I think you are getting paid only to send useless replies. The issue was raised on 27th May. On the same day of MidCap SELECT expiry. Further as you can see in the screen shot even 3rd June 11750 PE NIFSEL was missing from the csv file. But if you continue to make errors like these customers will continue to migrate to other better platforms. — Reply to this email directly, view it on GitHub<#102 (comment)>, or unsubscribehttps://github.com/notifications/unsubscribe-auth/A3TQZ424VUCK7SOSZLV2YFTZEVPPRAVCNFSM6AAAAABIK4DDK6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMZWGUZDINZUHA. You are receiving this because you commented.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).

Image attachment is not visible. Kindly login to github and upload the image attachment. Attachment via email is not working.