Actually, I have installed "py5paisa-0.3.1" too, but I was not able to logged in and getting this error "TypeError: 'NoneType' object is not subscriptable".
As a result, I moved back to older version "py5paisa-0.1.8" where I am able to logging into 5paisa account but not able to place an order and received following error while executing following command:
Code
from py5paisa.order import Order, OrderType, Exchange
File "", line 1, in
test_order = Order(order_type='B',exchange='N',exchange_segment='D', scrip_code=52875, quantity=50, price=205,is_intraday=True,atmarket=False)
Error Received
File "C:.....\py5paisa\order.py", line 64, in init
self.exchange = exchange.value
AttributeError: 'str' object has no attribute 'value'
Description
Actually, I have installed "py5paisa-0.3.1" too, but I was not able to logged in and getting this error "TypeError: 'NoneType' object is not subscriptable". As a result, I moved back to older version "py5paisa-0.1.8" where I am able to logging into 5paisa account but not able to place an order and received following error while executing following command:
Code from py5paisa.order import Order, OrderType, Exchange File "", line 1, in
test_order = Order(order_type='B',exchange='N',exchange_segment='D', scrip_code=52875, quantity=50, price=205,is_intraday=True,atmarket=False)
Error Received
File "C:.....\py5paisa\order.py", line 64, in init self.exchange = exchange.value
AttributeError: 'str' object has no attribute 'value'
Can you please rectify the issue