From 8a2fbf65923283efd0db0c61c316cc5df193089f Mon Sep 17 00:00:00 2001 From: Matthias Date: Sun, 13 Dec 2020 10:15:16 +0100 Subject: [PATCH] Small cleanup of protection stuff --- docs/includes/protections.md | 12 ++++++------ freqtrade/resolvers/protection_resolver.py | 2 -- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/docs/includes/protections.md b/docs/includes/protections.md index 7378a590c..87db17fd8 100644 --- a/docs/includes/protections.md +++ b/docs/includes/protections.md @@ -26,12 +26,12 @@ All protection end times are rounded up to the next candle to avoid sudden, unex | Parameter| Description | |------------|-------------| -| method | Protection name to use.
**Datatype:** String, selected from [available Protections](#available-protections) -| stop_duration_candles | For how many candles should the lock be set?
**Datatype:** Positive integer (in candles) -| stop_duration | how many minutes should protections be locked.
Cannot be used together with `stop_duration_candles`.
**Datatype:** Float (in minutes) +| `method` | Protection name to use.
**Datatype:** String, selected from [available Protections](#available-protections) +| `stop_duration_candles` | For how many candles should the lock be set?
**Datatype:** Positive integer (in candles) +| `stop_duration` | how many minutes should protections be locked.
Cannot be used together with `stop_duration_candles`.
**Datatype:** Float (in minutes) | `lookback_period_candles` | Only trades that completed within the last `lookback_period_candles` candles will be considered. This setting may be ignored by some Protections.
**Datatype:** Positive integer (in candles). -| lookback_period | Only trades that completed after `current_time - lookback_period` will be considered.
Cannot be used together with `lookback_period_candles`.
This setting may be ignored by some Protections.
**Datatype:** Float (in minutes) -| trade_limit | Number of trades required at minimum (not used by all Protections).
**Datatype:** Positive integer +| `lookback_period` | Only trades that completed after `current_time - lookback_period` will be considered.
Cannot be used together with `lookback_period_candles`.
This setting may be ignored by some Protections.
**Datatype:** Float (in minutes) +| `trade_limit` | Number of trades required at minimum (not used by all Protections).
**Datatype:** Positive integer !!! Note "Durations" Durations (`stop_duration*` and `lookback_period*` can be defined in either minutes or candles). @@ -108,7 +108,7 @@ The below example will stop trading a pair for 2 candles after closing a trade, "protections": [ { "method": "CooldownPeriod", - "stop_duration_candle": 2 + "stop_duration_candles": 2 } ], ``` diff --git a/freqtrade/resolvers/protection_resolver.py b/freqtrade/resolvers/protection_resolver.py index 928bd4633..c54ae1011 100644 --- a/freqtrade/resolvers/protection_resolver.py +++ b/freqtrade/resolvers/protection_resolver.py @@ -1,5 +1,3 @@ -# pragma pylint: disable=attribute-defined-outside-init - """ This module load custom pairlists """