Browse Source

fix: type ignore

pull/14/head
QuentinN42 1 year ago
parent
commit
27d5877fba
Signed by: number42 GPG Key ID: 2CD7D563712B3A50
  1. 2
      auto_trading/interfaces.py
  2. 13
      auto_trading/main.py

2
auto_trading/interfaces.py

@ -6,7 +6,7 @@ import logging
from abc import ABC, abstractmethod, abstractproperty
from dataclasses import dataclass, field
from datetime import timedelta, datetime
from pandas import DataFrame
from pandas import DataFrame # type: ignore
from typing import Dict, List, Optional, Any, Callable
from .errors import OrderException, UnknowOrder, PTFException

13
auto_trading/main.py

@ -3,18 +3,17 @@
One script to bring them all and in the darkness bind them
"""
import logging
from tqdm import tqdm
from tqdm import tqdm # type: ignore
from typing import List
from pandas import DataFrame
from pandas import DataFrame # type: ignore
from .interfaces import Order, CandlesProperties, DataBroker, Indicator, Strategy, PTF
from .errors import OrderException
from .interfaces import DataBroker, Strategy, PTF
class Bot:
"""The class that wrap all the classes together.
For more information, read /documentation/Diagramme.svg
"""
@ -27,7 +26,9 @@ class Bot:
def run(self):
"""run the bot"""
iterator = tqdm(self.broker) if self.logger.level >= logging.DEBUG else self.broker
iterator = (
tqdm(self.broker) if self.logger.level >= logging.DEBUG else self.broker
)
for data in iterator:
self.run_once(data)

Loading…
Cancel
Save