Skip to content

Commit c76ca00

Browse files
committed
Consider delisted symbol if ticker_time is None
1 parent 8a7a7cf commit c76ca00

File tree

4 files changed

+7
-3
lines changed

4 files changed

+7
-3
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

7+
## [1.0.4] - 2024-01-09
8+
### Fixed
9+
- Consider delisted symbol if `ticker_time` is None
10+
711
## [1.0.3] - 2024-01-08
812
### Fixed
913
- Add `None` check before restoring `best_triplet`

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<img src="illustration.jpeg" width="250px" height="250px" alt="Triangular illustration">
33
</p>
44

5-
# Triangular Arbitrage by OctoBot [1.0.3](https://github.com/Drakkar-Software/Triangular-Arbitrage/blob/master/CHANGELOG.md)
5+
# Triangular Arbitrage by OctoBot [1.0.4](https://github.com/Drakkar-Software/Triangular-Arbitrage/blob/master/CHANGELOG.md)
66
[![PyPI](https://img.shields.io/pypi/v/OctoBot-Triangular-Arbitrage.svg)](https://pypi.python.org/pypi/OctoBot-Triangular-Arbitrage/)
77
[![Dockerhub](https://img.shields.io/docker/pulls/drakkarsoftware/octobot-triangular-arbitrage.svg?logo=docker)](https://hub.docker.com/r/drakkarsoftware/octobot-triangular-arbitrage)
88

triangular_arbitrage/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
PROJECT_NAME = "OctoBot-Triangular-Arbitrage"
2-
VERSION = "1.0.3"
2+
VERSION = "1.0.4"

triangular_arbitrage/detector.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ def get_symbol_from_key(key_symbol: str) -> symbols.Symbol:
2727

2828
def is_delisted_symbols(exchange_time, ticker, threshold = 1 * constants.DAYS_TO_SECONDS * constants.MSECONDS_TO_SECONDS) -> bool:
2929
ticker_time = ticker['timestamp']
30-
return not (exchange_time - ticker_time <= threshold)
30+
return ticker_time is None or not (exchange_time - ticker_time <= threshold)
3131

3232
def get_last_prices(exchange_time, tickers, ignored_symbols):
3333
return [

0 commit comments

Comments
 (0)