prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  I get the same profit / loss report in all time frames
  <!-- 
  Have you searched for similar issues before posting it? Yes
  
  If you have discovered a bug in the bot, please [search our issue tracker](https://github.com/freqtrade/freqtrade/issues?q=is%3Aissue). 
  If it hasn't been reported, please create a new issue.
  
  Please do not use bug reports to request new features.
  -->
  
  ## Describe your environment
  
    * Operating system: ____Ubuntu 18.04.4 LTS
    * Python Version: _____Python 3.6.9
    * CCXT version: _____ ccxt==1.29.5
    * Freqtrade Version: ____ freqtrade develop-761407f7
    
  Today, I updated with the method below.
  cd freqtrade
  git pull
  python3 -m pip install -r requirements.txt --user
  python3 -m pip install -r requirements-hyperopt.txt --user
  python3 -m pip install -r requirements-plot.txt --user
  
  and
  freqtrade download-data --days 365 --timeframes  5m 15m 30m 1h 4h 1d
  https://github.com/freqtrade/freqtrade/issues/3104 (I keep getting this error on 1 and 5 minute candles)
  
  I use StaticPairList
  
  I did backtest as below
  freqtrade backtesting --strategy strateji --timerange=20200101- --ticker-interval 1m
  freqtrade backtesting --strategy strateji --timerange=20200101- --ticker-interval 5m
  freqtrade backtesting --strategy strateji --timerange=20200101- --ticker-interval 15m
  freqtrade backtesting --strategy strateji --timerange=20200101- --ticker-interval 30m
  freqtrade backtesting --strategy strateji --timerange=20200101- --ticker-interval 4h
  freqtrade backtesting --strategy strateji --timerange=20200101- --ticker-interval 1d
  
  The problem I encountered:
  I get the same profit / loss report in all time frames
  
  </issue>
  <code>
  [start of freqtrade/configuration/deprecated_settings.py]
  1 """
  2 Functions to handle deprecated settings
  3 """
  4 
  5 import logging
  6 from typing import Any, Dict
  7 
  8 from freqtrade.exceptions import OperationalException
  9 
  10 
  11 logger = logging.getLogger(__name__)
  12 
  13 
  14 def check_conflicting_settings(config: Dict[str, Any],
  15                                section1: str, name1: str,
  16                                section2: str, name2: str) -> None:
  17     section1_config = config.get(section1, {})
  18     section2_config = config.get(section2, {})
  19     if name1 in section1_config and name2 in section2_config:
  20         raise OperationalException(
  21             f"Conflicting settings `{section1}.{name1}` and `{section2}.{name2}` "
  22             "(DEPRECATED) detected in the configuration file. "
  23             "This deprecated setting will be removed in the next versions of Freqtrade. "
  24             f"Please delete it from your configuration and use the `{section1}.{name1}` "
  25             "setting instead."
  26         )
  27 
  28 
  29 def process_deprecated_setting(config: Dict[str, Any],
  30                                section1: str, name1: str,
  31                                section2: str, name2: str) -> None:
  32     section2_config = config.get(section2, {})
  33 
  34     if name2 in section2_config:
  35         logger.warning(
  36             "DEPRECATED: "
  37             f"The `{section2}.{name2}` setting is deprecated and "
  38             "will be removed in the next versions of Freqtrade. "
  39             f"Please use the `{section1}.{name1}` setting in your configuration instead."
  40         )
  41         section1_config = config.get(section1, {})
  42         section1_config[name1] = section2_config[name2]
  43 
  44 
  45 def process_temporary_deprecated_settings(config: Dict[str, Any]) -> None:
  46 
  47     check_conflicting_settings(config, 'ask_strategy', 'use_sell_signal',
  48                                'experimental', 'use_sell_signal')
  49     check_conflicting_settings(config, 'ask_strategy', 'sell_profit_only',
  50                                'experimental', 'sell_profit_only')
  51     check_conflicting_settings(config, 'ask_strategy', 'ignore_roi_if_buy_signal',
  52                                'experimental', 'ignore_roi_if_buy_signal')
  53 
  54     process_deprecated_setting(config, 'ask_strategy', 'use_sell_signal',
  55                                'experimental', 'use_sell_signal')
  56     process_deprecated_setting(config, 'ask_strategy', 'sell_profit_only',
  57                                'experimental', 'sell_profit_only')
  58     process_deprecated_setting(config, 'ask_strategy', 'ignore_roi_if_buy_signal',
  59                                'experimental', 'ignore_roi_if_buy_signal')
  60 
  61     if (config.get('edge', {}).get('enabled', False)
  62        and 'capital_available_percentage' in config.get('edge', {})):
  63         raise OperationalException(
  64             "DEPRECATED: "
  65             "Using 'edge.capital_available_percentage' has been deprecated in favor of "
  66             "'tradable_balance_ratio'. Please migrate your configuration to "
  67             "'tradable_balance_ratio' and remove 'capital_available_percentage' "
  68             "from the edge configuration."
  69         )
  70     if 'ticker_interval' in config:
  71         logger.warning(
  72             "DEPRECATED: "
  73             "Please use 'timeframe' instead of 'ticker_interval."
  74         )
  75         config['timeframe'] = config['ticker_interval']
  76
  [end of freqtrade/configuration/deprecated_settings.py]
  </code>
  
  I need you to solve this issue by generating a single patch file that I can apply directly to this repository using git apply. Please respond with a single patch file in the following format.
  <patch>
  diff --git a/file.py b/file.py
  --- a/file.py
  +++ b/file.py
  @@ -1,27 +1,35 @@
   def euclidean(a, b):
  -    while b:
  -        a, b = b, a % b
  -    return a
  +    if b == 0:
  +        return a
  +    return euclidean(b, a % b)
   
   
   def bresenham(x0, y0, x1, y1):
       points = []
       dx = abs(x1 - x0)
       dy = abs(y1 - y0)
  -    sx = 1 if x0 < x1 else -1
  -    sy = 1 if y0 < y1 else -1
  -    err = dx - dy
  +    x, y = x0, y0
  +    sx = -1 if x0 > x1 else 1
  +    sy = -1 if y0 > y1 else 1
   
  -    while True:
  -        points.append((x0, y0))
  -        if x0 == x1 and y0 == y1:
  -            break
  -        e2 = 2 * err
  -        if e2 > -dy:
  -            err -= dy
  -            x0 += sx
  -        if e2 < dx:
  -            err += dx
  -            y0 += sy
  +    if dx > dy:
  +        err = dx / 2.0
  +        while x != x1:
  +            points.append((x, y))
  +            err -= dy
  +            if err < 0:
  +                y += sy
  +                err += dx
  +            x += sx
  +    else:
  +        err = dy / 2.0
  +        while y != y1:
  +            points.append((x, y))
  +            err -= dx
  +            if err < 0:
  +                x += sx
  +                err += dy
  +            y += sy
  +
  +    points.append((x, y))
       return points
  
  </patch>
golden_diff: diff --git a/freqtrade/configuration/deprecated_settings.py b/freqtrade/configuration/deprecated_settings.py
  --- a/freqtrade/configuration/deprecated_settings.py
  +++ b/freqtrade/configuration/deprecated_settings.py
  @@ -72,4 +72,9 @@
               "DEPRECATED: "
               "Please use 'timeframe' instead of 'ticker_interval."
           )
  +        if 'timeframe' in config:
  +            raise OperationalException(
  +                "Both 'timeframe' and 'ticker_interval' detected."
  +                "Please remove 'ticker_interval' from your configuration to continue operating."
  +                )
           config['timeframe'] = config['ticker_interval']
  
verification_info: {"golden_diff": "diff --git a/freqtrade/configuration/deprecated_settings.py b/freqtrade/configuration/deprecated_settings.py\n--- a/freqtrade/configuration/deprecated_settings.py\n+++ b/freqtrade/configuration/deprecated_settings.py\n@@ -72,4 +72,9 @@\n             \"DEPRECATED: \"\n             \"Please use 'timeframe' instead of 'ticker_interval.\"\n         )\n+        if 'timeframe' in config:\n+            raise OperationalException(\n+                \"Both 'timeframe' and 'ticker_interval' detected.\"\n+                \"Please remove 'ticker_interval' from your configuration to continue operating.\"\n+                )\n         config['timeframe'] = config['ticker_interval']\n", "issue": "I get the same profit / loss report in all time frames\n<!-- \r\nHave you searched for similar issues before posting it? Yes\r\n\r\nIf you have discovered a bug in the bot, please [search our issue tracker](https://github.com/freqtrade/freqtrade/issues?q=is%3Aissue). \r\nIf it hasn't been reported, please create a new issue.\r\n\r\nPlease do not use bug reports to request new features.\r\n-->\r\n\r\n## Describe your environment\r\n\r\n  * Operating system: ____Ubuntu 18.04.4 LTS\r\n  * Python Version: _____Python 3.6.9\r\n  * CCXT version: _____ ccxt==1.29.5\r\n  * Freqtrade Version: ____ freqtrade develop-761407f7\r\n  \r\nToday, I updated with the method below.\r\ncd freqtrade\r\ngit pull\r\npython3 -m pip install -r requirements.txt --user\r\npython3 -m pip install -r requirements-hyperopt.txt --user\r\npython3 -m pip install -r requirements-plot.txt --user\r\n\r\nand\r\nfreqtrade download-data --days 365 --timeframes  5m 15m 30m 1h 4h 1d\r\nhttps://github.com/freqtrade/freqtrade/issues/3104 (I keep getting this error on 1 and 5 minute candles)\r\n\r\nI use StaticPairList\r\n\r\nI did backtest as below\r\nfreqtrade backtesting --strategy strateji --timerange=20200101- --ticker-interval 1m\r\nfreqtrade backtesting --strategy strateji --timerange=20200101- --ticker-interval 5m\r\nfreqtrade backtesting --strategy strateji --timerange=20200101- --ticker-interval 15m\r\nfreqtrade backtesting --strategy strateji --timerange=20200101- --ticker-interval 30m\r\nfreqtrade backtesting --strategy strateji --timerange=20200101- --ticker-interval 4h\r\nfreqtrade backtesting --strategy strateji --timerange=20200101- --ticker-interval 1d\r\n\r\nThe problem I encountered:\r\nI get the same profit / loss report in all time frames\n", "before_files": [{"content": "\"\"\"\nFunctions to handle deprecated settings\n\"\"\"\n\nimport logging\nfrom typing import Any, Dict\n\nfrom freqtrade.exceptions import OperationalException\n\n\nlogger = logging.getLogger(__name__)\n\n\ndef check_conflicting_settings(config: Dict[str, Any],\n                               section1: str, name1: str,\n                               section2: str, name2: str) -> None:\n    section1_config = config.get(section1, {})\n    section2_config = config.get(section2, {})\n    if name1 in section1_config and name2 in section2_config:\n        raise OperationalException(\n            f\"Conflicting settings `{section1}.{name1}` and `{section2}.{name2}` \"\n            \"(DEPRECATED) detected in the configuration file. \"\n            \"This deprecated setting will be removed in the next versions of Freqtrade. \"\n            f\"Please delete it from your configuration and use the `{section1}.{name1}` \"\n            \"setting instead.\"\n        )\n\n\ndef process_deprecated_setting(config: Dict[str, Any],\n                               section1: str, name1: str,\n                               section2: str, name2: str) -> None:\n    section2_config = config.get(section2, {})\n\n    if name2 in section2_config:\n        logger.warning(\n            \"DEPRECATED: \"\n            f\"The `{section2}.{name2}` setting is deprecated and \"\n            \"will be removed in the next versions of Freqtrade. \"\n            f\"Please use the `{section1}.{name1}` setting in your configuration instead.\"\n        )\n        section1_config = config.get(section1, {})\n        section1_config[name1] = section2_config[name2]\n\n\ndef process_temporary_deprecated_settings(config: Dict[str, Any]) -> None:\n\n    check_conflicting_settings(config, 'ask_strategy', 'use_sell_signal',\n                               'experimental', 'use_sell_signal')\n    check_conflicting_settings(config, 'ask_strategy', 'sell_profit_only',\n                               'experimental', 'sell_profit_only')\n    check_conflicting_settings(config, 'ask_strategy', 'ignore_roi_if_buy_signal',\n                               'experimental', 'ignore_roi_if_buy_signal')\n\n    process_deprecated_setting(config, 'ask_strategy', 'use_sell_signal',\n                               'experimental', 'use_sell_signal')\n    process_deprecated_setting(config, 'ask_strategy', 'sell_profit_only',\n                               'experimental', 'sell_profit_only')\n    process_deprecated_setting(config, 'ask_strategy', 'ignore_roi_if_buy_signal',\n                               'experimental', 'ignore_roi_if_buy_signal')\n\n    if (config.get('edge', {}).get('enabled', False)\n       and 'capital_available_percentage' in config.get('edge', {})):\n        raise OperationalException(\n            \"DEPRECATED: \"\n            \"Using 'edge.capital_available_percentage' has been deprecated in favor of \"\n            \"'tradable_balance_ratio'. Please migrate your configuration to \"\n            \"'tradable_balance_ratio' and remove 'capital_available_percentage' \"\n            \"from the edge configuration.\"\n        )\n    if 'ticker_interval' in config:\n        logger.warning(\n            \"DEPRECATED: \"\n            \"Please use 'timeframe' instead of 'ticker_interval.\"\n        )\n        config['timeframe'] = config['ticker_interval']\n", "path": "freqtrade/configuration/deprecated_settings.py"}]}