prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  .hypothesis should be in .gitignore
  **Describe the incorrect behavior you saw**
  
  `git diff` shows me an untracked `.hypothesis` directory.
  
  **Describe how to cause this behavior**
  
  I ran the tests.
  
  **Describe the correct behavior you'd like to see**
  
  `.hypothesis` [shouldn't be checked in](https://hypothesis.readthedocs.io/en/latest/database.html#the-hypothesis-example-database), so it should be ignored by `git`.
  
  </issue>
  <code>
  [start of .github/scripts/check-pr-text.py]
  1 #
  2 # This script is designed to be called by the GHA workflow.
  3 #
  4 # It is designed to check that the PR text complies to our dev standards.
  5 #
  6 # The input is received via the environmet variables:
  7 # * PR_TITLE - title of the PR
  8 # * PR_BODY - the description of the PR
  9 #
  10 # To test it run
  11 #
  12 # $ export PR_TITLE='#1234 Test Title'
  13 # $ export PR_BODY='some lines
  14 # > Fixes #12345
  15 # > more lines'
  16 # $ python3 .github/scripts/check-pr-text.py
  17 #
  18 import os
  19 import re
  20 import sys
  21 
  22 pr_title = os.environ.get("PR_TITLE", "")
  23 pr_body = os.environ.get("PR_BODY", "")
  24 
  25 print("--- DEBUG ---")
  26 print(f"Title: {pr_title}")
  27 print(f"Body:\n {pr_body}")
  28 print("-------------")
  29 
  30 
  31 def fail(message):
  32     print(message)
  33     print("Fix the title and then trigger a new push.")
  34     print("A re-run for this job will not work.")
  35     sys.exit(1)
  36 
  37 
  38 if not pr_title:
  39     fail("Title for the PR not found. " "Maybe missing PR_TITLE env var.")
  40 
  41 if not pr_body:
  42     fail("Body for the PR not found. " "Maybe missing PR_BODY env var.")
  43 
  44 title_search = re.search(r"^(#\d+) .+", pr_title)
  45 if not title_search:
  46     fail(
  47         "Title of PR has no issue ID reference. It must look like “#1234 Foo bar baz”."
  48     )
  49 else:
  50     print(f"PR title is complaint for {title_search[1]}. Good job.")
  51 
  52 
  53 body_search = re.search(r".*Fixes (#\d+).+", pr_body)
  54 if not body_search:
  55     fail('Body of PR has no "Fixes #12345" issue ID reference.')
  56 else:
  57     print(f"PR description is complaint for {body_search[1]}. Good job.")
  58 
  59 
  60 if title_search[1] != body_search[1]:
  61     fail("PR title and description have different IDs.")
  62 
  63 # All good.
  64 sys.exit(0)
  65
  [end of .github/scripts/check-pr-text.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/.github/scripts/check-pr-text.py b/.github/scripts/check-pr-text.py
  --- a/.github/scripts/check-pr-text.py
  +++ b/.github/scripts/check-pr-text.py
  @@ -41,7 +41,7 @@
   if not pr_body:
       fail("Body for the PR not found. " "Maybe missing PR_BODY env var.")
   
  -title_search = re.search(r"^(#\d+) .+", pr_title)
  +title_search = re.search(r"^(#\d+):? .+", pr_title)
   if not title_search:
       fail(
           "Title of PR has no issue ID reference. It must look like “#1234 Foo bar baz”."
  
verification_info: {"golden_diff": "diff --git a/.github/scripts/check-pr-text.py b/.github/scripts/check-pr-text.py\n--- a/.github/scripts/check-pr-text.py\n+++ b/.github/scripts/check-pr-text.py\n@@ -41,7 +41,7 @@\n if not pr_body:\n     fail(\"Body for the PR not found. \" \"Maybe missing PR_BODY env var.\")\n \n-title_search = re.search(r\"^(#\\d+) .+\", pr_title)\n+title_search = re.search(r\"^(#\\d+):? .+\", pr_title)\n if not title_search:\n     fail(\n         \"Title of PR has no issue ID reference. It must look like \u201c#1234 Foo bar baz\u201d.\"\n", "issue": ".hypothesis should be in .gitignore\n**Describe the incorrect behavior you saw**\r\n\r\n`git diff` shows me an untracked `.hypothesis` directory.\r\n\r\n**Describe how to cause this behavior**\r\n\r\nI ran the tests.\r\n\r\n**Describe the correct behavior you'd like to see**\r\n\r\n`.hypothesis` [shouldn't be checked in](https://hypothesis.readthedocs.io/en/latest/database.html#the-hypothesis-example-database), so it should be ignored by `git`.\n", "before_files": [{"content": "#\n# This script is designed to be called by the GHA workflow.\n#\n# It is designed to check that the PR text complies to our dev standards.\n#\n# The input is received via the environmet variables:\n# * PR_TITLE - title of the PR\n# * PR_BODY - the description of the PR\n#\n# To test it run\n#\n# $ export PR_TITLE='#1234 Test Title'\n# $ export PR_BODY='some lines\n# > Fixes #12345\n# > more lines'\n# $ python3 .github/scripts/check-pr-text.py\n#\nimport os\nimport re\nimport sys\n\npr_title = os.environ.get(\"PR_TITLE\", \"\")\npr_body = os.environ.get(\"PR_BODY\", \"\")\n\nprint(\"--- DEBUG ---\")\nprint(f\"Title: {pr_title}\")\nprint(f\"Body:\\n {pr_body}\")\nprint(\"-------------\")\n\n\ndef fail(message):\n    print(message)\n    print(\"Fix the title and then trigger a new push.\")\n    print(\"A re-run for this job will not work.\")\n    sys.exit(1)\n\n\nif not pr_title:\n    fail(\"Title for the PR not found. \" \"Maybe missing PR_TITLE env var.\")\n\nif not pr_body:\n    fail(\"Body for the PR not found. \" \"Maybe missing PR_BODY env var.\")\n\ntitle_search = re.search(r\"^(#\\d+) .+\", pr_title)\nif not title_search:\n    fail(\n        \"Title of PR has no issue ID reference. It must look like \u201c#1234 Foo bar baz\u201d.\"\n    )\nelse:\n    print(f\"PR title is complaint for {title_search[1]}. Good job.\")\n\n\nbody_search = re.search(r\".*Fixes (#\\d+).+\", pr_body)\nif not body_search:\n    fail('Body of PR has no \"Fixes #12345\" issue ID reference.')\nelse:\n    print(f\"PR description is complaint for {body_search[1]}. Good job.\")\n\n\nif title_search[1] != body_search[1]:\n    fail(\"PR title and description have different IDs.\")\n\n# All good.\nsys.exit(0)\n", "path": ".github/scripts/check-pr-text.py"}]}