Order execution and fetch erros
-
Here are are few things for @admin @bhaveshjain and developers to improve overall performance.
1 ) ORDER BOK FETCH ERROR
I fetch order book every 3 seconds.. Time to time I get the following error.
***** STORE NOTIF: While feteching order_book ***** STORE NOTIF: Invalid return character or leading space in header: X-ClientPublicIP ***** STORE NOTIF: While feteching order_book ***** STORE NOTIF: Invalid return character or leading space in header: X-ClientPublicIP
2) ORDER EXECUTION DELAYS
time to time there is a execution delay. I have logged the timestamp just before and after the order submission.
First order on same day
print ('Before order', datetime.datetime.now(timezone('Asia/Kolkata'))) oid = self.angel_api.placeOrder(orderparams) print ('After order', datetime.datetime.now(timezone('Asia/Kolkata')))
and this is what I get
Before order 2021-03-02 09:56:00.559882+05:30 After order 2021-03-02 09:56:12.755383+05:30
There is a 14 sec delay in submitting the order. Web screenshot here
Second order on same day
Before order 2021-03-02 11:07:01.003910+05:30 After order 2021-03-02 11:07:02.050287+05:30 `` This went well **Third order on same day**
Before order 2021-03-02 13:48:00.286036+05:30
After order 2021-03-02 13:48:16.498416+05:30
``
Thats a whopping 16 sec delayFourth order on same day
Before order 2021-03-02 15:16:11.160462+05:30 After order 2021-03-02 15:16:12.340260+05:30
Im sitting on a Gigabit network and some orders to go well in time. Please have a look at this delays. This is very crucial for trading.
Also im using your official python SDK and not my own headers etc.
3) Please include reconnect module in python SDK
Time to time I get heartbeat failed message. I have posted here before pointing to the fact that python SDK doesn't have a reconnect module while official GO module has it.
4) Please include open and oi in the websockets
This has been long pending and difficult work with some strategies without oi. Open is crucial for open range breakouts.
Thanks
-
@rajanprabu
Thank you sir.
Day by day your contribution to this forum helping us immensely. -
Yes.. its simply
time before order time after delta = after - before
so this has round trip time also.. Real time from script to order could be ever short.
-
@rajanprabu said in Order execution and fetch erros:
It took roughly 70 ms today ( from Mumbai aws ). This is great improvement from the past
Did you use same datetime function from python to measure time required to complete your request ?
-
Happy to here that. I too waiting for OI to be streamed via WS.
Thank you @rajanprabu to update on this.
-
@rajanprabu said in Order execution and fetch erros:
1 ) ORDER BOK FETCH ERROR
New SDK completely fixed it. Checked last 3 days, and didnt get the error message again.
@rajanprabu said in Order execution and fetch erros:
- ORDER EXECUTION DELAYS
It took roughly 70 ms today ( from Mumbai aws ). This is great improvement from the past
@rajanprabu said in Order execution and fetch erros:
- Please include reconnect module in python SDK
I didnt get time to test this, but I see the module present in the new SDK. Thanks for implementing this.
@rajanprabu said in Order execution and fetch erros:
- Please include open and oi in the websockets
I believe this is coming soon. so does the ms timestamp in order book.
overall nearly all issues are addressed. Thank you much @admin to take forward the user inputs and fix the issues for the users Kudos. well done.
-
hi@rajanprabhu we have noticed your issue we will update you on this.