prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  [Bug]: was_wolfsburg_de stopped fetching data
  ### I Have A Problem With:
  
  A specific source
  
  ### What's Your Problem
  
  The Source was_wolfsburg_de stopped fetching data for 2024. I suspect because the request link is no longer accurate.
  I have experimented a bit, and with the following address I receive current data: 
  
  https://was-wolfsburg.de/subabfuhrtermine/php/abfuhrtermine.php
  
  It only concerns "Restmüll, Bioabfall und Papierabfall". "Gelber Sack" is still functioning.
  
  ### Source (if relevant)
  
  was_wolfsburg_de
  
  ### Logs
  
  _No response_
  
  ### Relevant Configuration
  
  _No response_
  
  ### Checklist Source Error
  
  - [ ] Use the example parameters for your source (often available in the documentation) (don't forget to restart Home Assistant after changing the configuration)
  - [ ] Checked that the website of your service provider is still working
  - [ ] Tested my attributes on the service provider website (if possible)
  - [X] I have tested with the latest version of the integration (master) (for HACS in the 3 dot menu of the integration click on "Redownload" and choose master as version)
  
  ### Checklist Sensor Error
  
  - [ ] Checked in the Home Assistant Calendar tab if the event names match the types names (if types argument is used)
  
  ### Required
  
  - [X] I have searched past (closed AND opened) issues to see if this bug has already been reported, and it hasn't been.
  - [X] I understand that people give their precious time for free, and thus I've done my very best to make this problem as easy as possible to investigate.
  
  </issue>
  <code>
  [start of custom_components/waste_collection_schedule/waste_collection_schedule/source/was_wolfsburg_de.py]
  1 import datetime
  2 import re
  3 
  4 import requests
  5 from waste_collection_schedule import Collection  # type: ignore[attr-defined]
  6 from waste_collection_schedule.service.ICS import ICS
  7 
  8 TITLE = "Wolfsburger Abfallwirtschaft und Straßenreinigung"
  9 DESCRIPTION = "Source for waste collections for WAS-Wolfsburg, Germany."
  10 URL = "https://was-wolfsburg.de"
  11 TEST_CASES = {
  12     "Barnstorf": {"city": "Barnstorf", "street": "Bahnhofspassage"},
  13     "Sülfeld": {"city": "Sülfeld", "street": "Bärheide"},
  14 }
  15 CHARACTER_MAP = {
  16     ord("ü"): "u",
  17     ord("ö"): "o",  # doesn't appear to be needed
  18     ord("ä"): "a",  # doesn't appear to be needed
  19 }
  20 
  21 
  22 class Source:
  23     def __init__(self, city: str, street: str):
  24         self._city = city.translate(CHARACTER_MAP)
  25         self._street = street.translate(CHARACTER_MAP)
  26         self._ics = ICS()
  27 
  28     def fetch(self):
  29         # fetch "Gelber Sack"
  30         args = {"g": self._city}
  31         r = requests.get(
  32             "https://was-wolfsburg.de/subgelberweihgarten/php/abfuhrgelber.php",
  33             params=args,
  34         )
  35 
  36         entries = []
  37         match = re.findall(r"(\d{2})\.(\d{2})\.(\d{4})", r.text)
  38         for m in match:
  39             date = datetime.date(day=int(m[0]), month=int(m[1]), year=int(m[2]))
  40             entries.append(Collection(date, "Gelber Sack"))
  41 
  42         # fetch remaining collections
  43         args = {"ortabf": self._street}
  44         r = requests.post(
  45             "https://was-wolfsburg.de/subabfuhrtermine/ics_abfuhrtermine3.php",
  46             data=args,
  47         )
  48         dates = self._ics.convert(r.text)
  49         for d in dates:
  50             entries.append(Collection(d[0], d[1]))
  51 
  52         return entries
  53
  [end of custom_components/waste_collection_schedule/waste_collection_schedule/source/was_wolfsburg_de.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/custom_components/waste_collection_schedule/waste_collection_schedule/source/was_wolfsburg_de.py b/custom_components/waste_collection_schedule/waste_collection_schedule/source/was_wolfsburg_de.py
  --- a/custom_components/waste_collection_schedule/waste_collection_schedule/source/was_wolfsburg_de.py
  +++ b/custom_components/waste_collection_schedule/waste_collection_schedule/source/was_wolfsburg_de.py
  @@ -12,6 +12,14 @@
       "Barnstorf": {"city": "Barnstorf", "street": "Bahnhofspassage"},
       "Sülfeld": {"city": "Sülfeld", "street": "Bärheide"},
   }
  +
  +ICON_MAP = {
  +    "Gelber Sack": "mdi:recycle",
  +    "Bioabfall": "mdi:leaf",
  +    "Restabfall": "mdi:trash-can",
  +    "Altpapier": "mdi:file-document-outline",
  +}
  +
   CHARACTER_MAP = {
       ord("ü"): "u",
       ord("ö"): "o",  # doesn't appear to be needed
  @@ -37,16 +45,21 @@
           match = re.findall(r"(\d{2})\.(\d{2})\.(\d{4})", r.text)
           for m in match:
               date = datetime.date(day=int(m[0]), month=int(m[1]), year=int(m[2]))
  -            entries.append(Collection(date, "Gelber Sack"))
  +            entries.append(
  +                Collection(date, "Gelber Sack", icon=ICON_MAP["Gelber Sack"])
  +            )
   
           # fetch remaining collections
  -        args = {"ortabf": self._street}
  -        r = requests.post(
  -            "https://was-wolfsburg.de/subabfuhrtermine/ics_abfuhrtermine3.php",
  -            data=args,
  +        args = {"k": self._street}
  +        r = requests.get(
  +            "https://was-wolfsburg.de/subabfuhrtermine/php/abfuhrtermine.php",
  +            params=args,
  +        )
  +        match = re.findall(
  +            r"(\d{2})\.(\d{2})\.(\d{4}).*?<em>\s*([A-Za-z- ]+)\s*</em>", r.text
           )
  -        dates = self._ics.convert(r.text)
  -        for d in dates:
  -            entries.append(Collection(d[0], d[1]))
  +        for m in match:
  +            date = datetime.date(day=int(m[0]), month=int(m[1]), year=int(m[2]))
  +            entries.append(Collection(date, m[3], icon=ICON_MAP[m[3]]))
   
           return entries
  
verification_info: {"golden_diff": "diff --git a/custom_components/waste_collection_schedule/waste_collection_schedule/source/was_wolfsburg_de.py b/custom_components/waste_collection_schedule/waste_collection_schedule/source/was_wolfsburg_de.py\n--- a/custom_components/waste_collection_schedule/waste_collection_schedule/source/was_wolfsburg_de.py\n+++ b/custom_components/waste_collection_schedule/waste_collection_schedule/source/was_wolfsburg_de.py\n@@ -12,6 +12,14 @@\n     \"Barnstorf\": {\"city\": \"Barnstorf\", \"street\": \"Bahnhofspassage\"},\n     \"S\u00fclfeld\": {\"city\": \"S\u00fclfeld\", \"street\": \"B\u00e4rheide\"},\n }\n+\n+ICON_MAP = {\n+    \"Gelber Sack\": \"mdi:recycle\",\n+    \"Bioabfall\": \"mdi:leaf\",\n+    \"Restabfall\": \"mdi:trash-can\",\n+    \"Altpapier\": \"mdi:file-document-outline\",\n+}\n+\n CHARACTER_MAP = {\n     ord(\"\u00fc\"): \"u\",\n     ord(\"\u00f6\"): \"o\",  # doesn't appear to be needed\n@@ -37,16 +45,21 @@\n         match = re.findall(r\"(\\d{2})\\.(\\d{2})\\.(\\d{4})\", r.text)\n         for m in match:\n             date = datetime.date(day=int(m[0]), month=int(m[1]), year=int(m[2]))\n-            entries.append(Collection(date, \"Gelber Sack\"))\n+            entries.append(\n+                Collection(date, \"Gelber Sack\", icon=ICON_MAP[\"Gelber Sack\"])\n+            )\n \n         # fetch remaining collections\n-        args = {\"ortabf\": self._street}\n-        r = requests.post(\n-            \"https://was-wolfsburg.de/subabfuhrtermine/ics_abfuhrtermine3.php\",\n-            data=args,\n+        args = {\"k\": self._street}\n+        r = requests.get(\n+            \"https://was-wolfsburg.de/subabfuhrtermine/php/abfuhrtermine.php\",\n+            params=args,\n+        )\n+        match = re.findall(\n+            r\"(\\d{2})\\.(\\d{2})\\.(\\d{4}).*?<em>\\s*([A-Za-z- ]+)\\s*</em>\", r.text\n         )\n-        dates = self._ics.convert(r.text)\n-        for d in dates:\n-            entries.append(Collection(d[0], d[1]))\n+        for m in match:\n+            date = datetime.date(day=int(m[0]), month=int(m[1]), year=int(m[2]))\n+            entries.append(Collection(date, m[3], icon=ICON_MAP[m[3]]))\n \n         return entries\n", "issue": "[Bug]: was_wolfsburg_de stopped fetching data\n### I Have A Problem With:\n\nA specific source\n\n### What's Your Problem\n\nThe Source was_wolfsburg_de stopped fetching data for 2024. I suspect because the request link is no longer accurate.\r\nI have experimented a bit, and with the following address I receive current data: \r\n\r\nhttps://was-wolfsburg.de/subabfuhrtermine/php/abfuhrtermine.php\r\n\r\nIt only concerns \"Restm\u00fcll, Bioabfall und Papierabfall\". \"Gelber Sack\" is still functioning.\n\n### Source (if relevant)\n\nwas_wolfsburg_de\n\n### Logs\n\n_No response_\n\n### Relevant Configuration\n\n_No response_\n\n### Checklist Source Error\n\n- [ ] Use the example parameters for your source (often available in the documentation) (don't forget to restart Home Assistant after changing the configuration)\n- [ ] Checked that the website of your service provider is still working\n- [ ] Tested my attributes on the service provider website (if possible)\n- [X] I have tested with the latest version of the integration (master) (for HACS in the 3 dot menu of the integration click on \"Redownload\" and choose master as version)\n\n### Checklist Sensor Error\n\n- [ ] Checked in the Home Assistant Calendar tab if the event names match the types names (if types argument is used)\n\n### Required\n\n- [X] I have searched past (closed AND opened) issues to see if this bug has already been reported, and it hasn't been.\n- [X] I understand that people give their precious time for free, and thus I've done my very best to make this problem as easy as possible to investigate.\n", "before_files": [{"content": "import datetime\nimport re\n\nimport requests\nfrom waste_collection_schedule import Collection  # type: ignore[attr-defined]\nfrom waste_collection_schedule.service.ICS import ICS\n\nTITLE = \"Wolfsburger Abfallwirtschaft und Stra\u00dfenreinigung\"\nDESCRIPTION = \"Source for waste collections for WAS-Wolfsburg, Germany.\"\nURL = \"https://was-wolfsburg.de\"\nTEST_CASES = {\n    \"Barnstorf\": {\"city\": \"Barnstorf\", \"street\": \"Bahnhofspassage\"},\n    \"S\u00fclfeld\": {\"city\": \"S\u00fclfeld\", \"street\": \"B\u00e4rheide\"},\n}\nCHARACTER_MAP = {\n    ord(\"\u00fc\"): \"u\",\n    ord(\"\u00f6\"): \"o\",  # doesn't appear to be needed\n    ord(\"\u00e4\"): \"a\",  # doesn't appear to be needed\n}\n\n\nclass Source:\n    def __init__(self, city: str, street: str):\n        self._city = city.translate(CHARACTER_MAP)\n        self._street = street.translate(CHARACTER_MAP)\n        self._ics = ICS()\n\n    def fetch(self):\n        # fetch \"Gelber Sack\"\n        args = {\"g\": self._city}\n        r = requests.get(\n            \"https://was-wolfsburg.de/subgelberweihgarten/php/abfuhrgelber.php\",\n            params=args,\n        )\n\n        entries = []\n        match = re.findall(r\"(\\d{2})\\.(\\d{2})\\.(\\d{4})\", r.text)\n        for m in match:\n            date = datetime.date(day=int(m[0]), month=int(m[1]), year=int(m[2]))\n            entries.append(Collection(date, \"Gelber Sack\"))\n\n        # fetch remaining collections\n        args = {\"ortabf\": self._street}\n        r = requests.post(\n            \"https://was-wolfsburg.de/subabfuhrtermine/ics_abfuhrtermine3.php\",\n            data=args,\n        )\n        dates = self._ics.convert(r.text)\n        for d in dates:\n            entries.append(Collection(d[0], d[1]))\n\n        return entries\n", "path": "custom_components/waste_collection_schedule/waste_collection_schedule/source/was_wolfsburg_de.py"}]}