prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  Build number in -dev versioning
  Since we do not have a build number in the -dev version, it may be quite complex to understand which particular version of freqtrade the user runs (especially with that your conda). So if we change user interface I guess it's better for a while to make those changes along with changing the version of both develop and master...
  
  Is it possible to introduce the build number into the -dev versioning, which will change with every merge, as ccxt employs, for example?
  
  It's not necessary for master (2019-8 is completely enough), but for develop changing every day this may be useful since `freqtrade -V` will give particular version info (even when a user has current codebase from github fetched in a dir, but installed an outdated version with that your conda, which is used instead of latest develop from the dir; that's the confusing usecase when it's complicated to find out the actual version of freqtrade that runs at the user site...)
  
  It's not necessary to be an increasing number, it can be a short commit id (merged into develop), for example...
  
  
  </issue>
  <code>
  [start of freqtrade/__init__.py]
  1 """ FreqTrade bot """
  2 __version__ = '2019.7-dev'
  3 
  4 
  5 class DependencyException(Exception):
  6     """
  7     Indicates that an assumed dependency is not met.
  8     This could happen when there is currently not enough money on the account.
  9     """
  10 
  11 
  12 class OperationalException(Exception):
  13     """
  14     Requires manual intervention and will usually stop the bot.
  15     This happens when an exchange returns an unexpected error during runtime
  16     or given configuration is invalid.
  17     """
  18 
  19 
  20 class InvalidOrderException(Exception):
  21     """
  22     This is returned when the order is not valid. Example:
  23     If stoploss on exchange order is hit, then trying to cancel the order
  24     should return this exception.
  25     """
  26 
  27 
  28 class TemporaryError(Exception):
  29     """
  30     Temporary network or exchange related error.
  31     This could happen when an exchange is congested, unavailable, or the user
  32     has networking problems. Usually resolves itself after a time.
  33     """
  34
  [end of freqtrade/__init__.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/__init__.py b/freqtrade/__init__.py
  --- a/freqtrade/__init__.py
  +++ b/freqtrade/__init__.py
  @@ -1,5 +1,16 @@
   """ FreqTrade bot """
  -__version__ = '2019.7-dev'
  +__version__ = 'develop'
  +
  +if __version__ == 'develop':
  +
  +    try:
  +        import subprocess
  +        __version__ = 'develop-' + subprocess.check_output(
  +            ['git', 'log', '--format="%h"', '-n 1'],
  +            stderr=subprocess.DEVNULL).decode("utf-8").rstrip().strip('"')
  +    except Exception:
  +        # git not available, ignore
  +        pass
   
   
   class DependencyException(Exception):
  
verification_info: {"golden_diff": "diff --git a/freqtrade/__init__.py b/freqtrade/__init__.py\n--- a/freqtrade/__init__.py\n+++ b/freqtrade/__init__.py\n@@ -1,5 +1,16 @@\n \"\"\" FreqTrade bot \"\"\"\n-__version__ = '2019.7-dev'\n+__version__ = 'develop'\n+\n+if __version__ == 'develop':\n+\n+    try:\n+        import subprocess\n+        __version__ = 'develop-' + subprocess.check_output(\n+            ['git', 'log', '--format=\"%h\"', '-n 1'],\n+            stderr=subprocess.DEVNULL).decode(\"utf-8\").rstrip().strip('\"')\n+    except Exception:\n+        # git not available, ignore\n+        pass\n \n \n class DependencyException(Exception):\n", "issue": "Build number in -dev versioning\nSince we do not have a build number in the -dev version, it may be quite complex to understand which particular version of freqtrade the user runs (especially with that your conda). So if we change user interface I guess it's better for a while to make those changes along with changing the version of both develop and master...\r\n\r\nIs it possible to introduce the build number into the -dev versioning, which will change with every merge, as ccxt employs, for example?\r\n\r\nIt's not necessary for master (2019-8 is completely enough), but for develop changing every day this may be useful since `freqtrade -V` will give particular version info (even when a user has current codebase from github fetched in a dir, but installed an outdated version with that your conda, which is used instead of latest develop from the dir; that's the confusing usecase when it's complicated to find out the actual version of freqtrade that runs at the user site...)\r\n\r\nIt's not necessary to be an increasing number, it can be a short commit id (merged into develop), for example...\r\n\n", "before_files": [{"content": "\"\"\" FreqTrade bot \"\"\"\n__version__ = '2019.7-dev'\n\n\nclass DependencyException(Exception):\n    \"\"\"\n    Indicates that an assumed dependency is not met.\n    This could happen when there is currently not enough money on the account.\n    \"\"\"\n\n\nclass OperationalException(Exception):\n    \"\"\"\n    Requires manual intervention and will usually stop the bot.\n    This happens when an exchange returns an unexpected error during runtime\n    or given configuration is invalid.\n    \"\"\"\n\n\nclass InvalidOrderException(Exception):\n    \"\"\"\n    This is returned when the order is not valid. Example:\n    If stoploss on exchange order is hit, then trying to cancel the order\n    should return this exception.\n    \"\"\"\n\n\nclass TemporaryError(Exception):\n    \"\"\"\n    Temporary network or exchange related error.\n    This could happen when an exchange is congested, unavailable, or the user\n    has networking problems. Usually resolves itself after a time.\n    \"\"\"\n", "path": "freqtrade/__init__.py"}]}