Tim55667757 / TKSBrokerAPI

TKSBrokerAPI is the trading platform for automation and simplifying the implementation of trading scenarios, as well as working with Tinkoff Invest API server via the REST protocol. The TKSBrokerAPI platform may be used in two ways: from the console, it has a rich keys and commands, or you can use it as Python module.
https://tim55667757.github.io/TKSBrokerAPI/
Apache License 2.0
25 stars 9 forks source link

KeyError: 'name' #135

Open Vasasago opened 10 months ago

Vasasago commented 10 months ago

запустил пример из readme с торговлей по объемам, выдает ошибку main.py L:42 INFO [2023-11-07 16:45:17,481] --- Ticker [ROSN], data analysis... Traceback (most recent call last): File "C:\Users\Vassago\PycharmProjects\bot\main.py", line 47, in portfolio = trader.Overview(show=False) # TKSBrokerAPI: https://tim55667757.github.io/TKSBrokerAPI/docs/tksbrokerapi/TKSBrokerAPI.html#TinkoffBrokerServer.Overview File "C:\Users\Vassago\PycharmProjects\bot\venv\lib\site-packages\tksbrokerapi\TKSBrokerAPI.py", line 1695, in Overview "name": curr["name"], KeyError: 'name'

ЛОГ:

main.py L:16 DEBUG [2023-11-07 16:45:17,347] =--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--= main.py L:17 DEBUG [2023-11-07 16:45:17,347] Trading scenario started at: [2023-11-07 13:45:17] UTC, it is [2023-11-07 16:45:17] local time TKSBrokerAPI.py L:108 DEBUG [2023-11-07 16:45:17,347] Bearer token for Tinkoff OpenAPI set up from class variable token TKSBrokerAPI.py L:120 DEBUG [2023-11-07 16:45:17,347] Main account ID [2205451368] set up from class variable accountId TKSBrokerAPI.py L:165 DEBUG [2023-11-07 16:45:17,348] Broker API server: https://invest-public-api.tinkoff.ru/rest TKSBrokerAPI.py L:339 DEBUG [2023-11-07 16:45:17,481] Local cache with raw instruments data is used: [C:\Users\Vassago\PycharmProjects\copybot\dump.json]. Last modified: [2023-11-07 13:32:11] UTC main.py L:42 INFO [2023-11-07 16:45:17,481] --- Ticker [ROSN], data analysis... TKSBrokerAPI.py L:1671 DEBUG [2023-11-07 16:45:17,481] Requesting portfolio of a client. Wait, please... TKSBrokerAPI.py L:1512 DEBUG [2023-11-07 16:45:17,481] Requesting current actual user's portfolio. Wait, please... TKSBrokerAPI.py L:1537 DEBUG [2023-11-07 16:45:17,848] Requesting current open positions in currencies and instruments. Wait, please... TKSBrokerAPI.py L:1562 DEBUG [2023-11-07 16:45:18,214] Requesting current actual pending limit orders. Wait, please... TKSBrokerAPI.py L:1568 DEBUG [2023-11-07 16:45:18,524] [0] records about pending limit orders received TKSBrokerAPI.py L:1586 DEBUG [2023-11-07 16:45:18,524] Requesting current actual stop orders. Wait, please... TKSBrokerAPI.py L:1592 DEBUG [2023-11-07 16:45:18,819] [1] records about stop orders received