From 59e881c59ddbd83e66926bad6ad2d80887ac48e7 Mon Sep 17 00:00:00 2001 From: hroff-1902 Date: Thu, 24 Oct 2019 23:11:07 +0300 Subject: [PATCH] Remove obsolete scripts --- scripts/download_backtest_data.py | 11 ---- scripts/get_market_pairs.py | 103 ------------------------------ scripts/plot_dataframe.py | 11 ---- scripts/plot_profit.py | 11 ---- {scripts => tests}/pytest.sh | 0 5 files changed, 136 deletions(-) delete mode 100755 scripts/download_backtest_data.py delete mode 100644 scripts/get_market_pairs.py delete mode 100755 scripts/plot_dataframe.py delete mode 100755 scripts/plot_profit.py rename {scripts => tests}/pytest.sh (100%) diff --git a/scripts/download_backtest_data.py b/scripts/download_backtest_data.py deleted file mode 100755 index a8f919a10..000000000 --- a/scripts/download_backtest_data.py +++ /dev/null @@ -1,11 +0,0 @@ -#!/usr/bin/env python3 - -import sys - - -print("This script has been integrated into freqtrade " - "and its functionality is available by calling `freqtrade download-data`.") -print("Please check the documentation on https://www.freqtrade.io/en/latest/backtesting/ " - "for details.") - -sys.exit(1) diff --git a/scripts/get_market_pairs.py b/scripts/get_market_pairs.py deleted file mode 100644 index cd38bf2fa..000000000 --- a/scripts/get_market_pairs.py +++ /dev/null @@ -1,103 +0,0 @@ -""" -This script was adapted from ccxt here: -https://github.com/ccxt/ccxt/blob/master/examples/py/arbitrage-pairs.py -""" -import os -import sys -import traceback - -root = os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) -sys.path.append(root + '/python') - -import ccxt # noqa: E402 - - -def style(s, style): - return style + s + '\033[0m' - - -def green(s): - return style(s, '\033[92m') - - -def blue(s): - return style(s, '\033[94m') - - -def yellow(s): - return style(s, '\033[93m') - - -def red(s): - return style(s, '\033[91m') - - -def pink(s): - return style(s, '\033[95m') - - -def bold(s): - return style(s, '\033[1m') - - -def underline(s): - return style(s, '\033[4m') - - -def dump(*args): - print(' '.join([str(arg) for arg in args])) - - -def print_supported_exchanges(): - dump('Supported exchanges:', green(', '.join(ccxt.exchanges))) - - -try: - - if len(sys.argv) < 2: - dump("Usage: python " + sys.argv[0], green('id')) - print_supported_exchanges() - sys.exit(1) - - id = sys.argv[1] # get exchange id from command line arguments - - # check if the exchange is supported by ccxt - exchange_found = id in ccxt.exchanges - - if exchange_found: - dump('Instantiating', green(id), 'exchange') - - # instantiate the exchange by id - exchange = getattr(ccxt, id)({ - # 'proxy':'https://cors-anywhere.herokuapp.com/', - }) - - # load all markets from the exchange - markets = exchange.load_markets() - - # output a list of all market symbols - dump(green(id), 'has', len(exchange.symbols), 'symbols:', exchange.symbols) - - tuples = list(ccxt.Exchange.keysort(markets).items()) - - # debug - for (k, v) in tuples: - print(v) - - # output a table of all markets - dump(pink('{:<15} {:<15} {:<15} {:<15}'.format('id', 'symbol', 'base', 'quote'))) - - for (k, v) in tuples: - dump('{:<15} {:<15} {:<15} {:<15}'.format(v['id'], v['symbol'], v['base'], v['quote'])) - - else: - - dump('Exchange ' + red(id) + ' not found') - print_supported_exchanges() - -except Exception as e: - dump('[' + type(e).__name__ + ']', str(e)) - dump(traceback.format_exc()) - dump("Usage: python " + sys.argv[0], green('id')) - print_supported_exchanges() - sys.exit(1) diff --git a/scripts/plot_dataframe.py b/scripts/plot_dataframe.py deleted file mode 100755 index 62c4bc39f..000000000 --- a/scripts/plot_dataframe.py +++ /dev/null @@ -1,11 +0,0 @@ -#!/usr/bin/env python3 - -import sys - - -print("This script has been integrated into freqtrade " - "and its functionality is available by calling `freqtrade plot-dataframe`.") -print("Please check the documentation on https://www.freqtrade.io/en/latest/plotting/ " - "for details.") - -sys.exit(1) diff --git a/scripts/plot_profit.py b/scripts/plot_profit.py deleted file mode 100755 index c9a23c1ee..000000000 --- a/scripts/plot_profit.py +++ /dev/null @@ -1,11 +0,0 @@ -#!/usr/bin/env python3 - -import sys - - -print("This script has been integrated into freqtrade " - "and its functionality is available by calling `freqtrade plot-profit`.") -print("Please check the documentation on https://www.freqtrade.io/en/latest/plotting/ " - "for details.") - -sys.exit(1) diff --git a/scripts/pytest.sh b/tests/pytest.sh similarity index 100% rename from scripts/pytest.sh rename to tests/pytest.sh