These seems to be some issue while fecthing the data for Indices,
will check on this
@Tradehull_Imran
I have the same issue, seems like some stocks are not recognized there it stops, i removed these stocks code worked then gain stopped at some other stock.
after adding the code u gave, code is continuing the loop, but those stocks keep showing the same error, but code is ignoring that… thanks
Hi Imran,
This worked thank you.
but why we are allowing chart as none.? we don’t need chart?
@Tradehull_Imran Yes Sir, it works now. I understand the mistake that I made. Thanks a lot sir.
we are not allowing the code when chart is None,
when we get chart value as None…
------- then the code goes to continue…
-------------- continue then sends it to for loop (line 26)
so essentially continue restarts the loop from the last location
Got it. thank you so much for quick reply
HI Imran
Thanks. This is working but fetched data is not real time data.
need session5 file
Hi @Tradehull_Imran
Traceback (most recent call last):
File “/Users/shreyasavinashpasarkar/Python Projects/3. Session3 - Codebase/3. Session3 - Codebase/Dhan codebase/Dhan_Tradehull.py”, line 139, in order_placement
orderid = order[“data”][“orderId”]
~~~~~~~~~~~~~^^^^^^^^^^^
TypeError: string indices must be integers, not ‘str’
–Return–
when i put this code to pdb sell_entry_orderid = tsl.order_placement(stock_name, ‘NSE’, 1, 0,0,‘MARKET’, ‘SELL’, ‘MIS’)
then this eroor shows?
reply fast sir
@Tradehull_Imran sir
I am also getting same error, rest everything is working fine…
ITC is in uptrend, Buy this script
[0] > ←[33;01mc:\users\zee2z\onedrive\desktop\dhan_2\session 6\1st_algo\testing.py←[00m(←[36;01m60←[00m)()
→ qty = int(margin/bc[‘close’])
(Pdb++) stock_name
‘ITC’
(Pdb++) buy_entry_orderid = tsl.order_placement(stock_name,‘NSE’, 1, 0, 0, ‘MARKET’, ‘BUY’, ‘MIS’)
Traceback (most recent call last):
File “C:\Users\zee2z\AppData\Local\Programs\Python\Python38\lib\cmd.py”, line 214, in onecmd
func = getattr(self, ‘do_’ + cmd)
AttributeError: ‘Pdb’ object has no attribute ‘do_buy_entry_orderid’
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File “C:\Users\zee2z\OneDrive\Desktop\Dhan_2\Session 6\1st_Algo\Dhan_Tradehull.py”, line 139, in order_placement
orderid = order[“data”][“orderId”]
TypeError: string indices must be integers
(Pdb++)
Hi @CBrid
Tomorrow, Send the data screenshot with timestamp, so that it can be checked.
Hi everyone,
Session 5
Session 6
Hi @Spasarkar04 @Zee2Zahid @Md_Naquibuddin
Orders were placed after market was over, this may be a cause.
Do check it in live market tomorrow and update if it is working
Thank you , sir, Problem is solved
Hi everyone,
I want to check if this topic is of interest.
Live tick by tick data Options Chain
Lets say,
If I get enough comments on this expressing their interest, I will assume yes that this topic is required and will make in-depth video for it.
Yes we are superrr excited for this
@Tradehull_Imran sir
We are super interested.
![]()
interested sir
Yes… Very useful topic.

