prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  Partner page partner blocks keep showing the loading animation
  ### Describe the bug
  Partner page partner blocks keep showing the loading animation.
  
  ### How to reproduce
  Steps to reproduce the behaviour:
  1. Go to [the Thalia partner page](https://thalia.nu/career/).
  2. Scroll down and see the loading animation on the partner blocks.
  
  ### Expected behaviour
  The loading animation should stop when the partners have been loaded.
  
  
  </issue>
  <code>
  [start of website/thaliawebsite/templatetags/grid_item.py]
  1 from django import template
  2 
  3 register = template.Library()
  4 
  5 
  6 @register.inclusion_tag("includes/grid_item.html")
  7 def grid_item(
  8     title=None,
  9     meta_text="",
  10     url=None,
  11     image_url=None,
  12     ribbon=None,
  13     class_name="",
  14     anchor_attrs="",
  15 ):
  16     return {
  17         "title": title,
  18         "url": url,
  19         "image_url": image_url,
  20         "meta_text": meta_text,
  21         "ribbon": ribbon,
  22         "class_name": class_name,
  23         "anchor_attrs": anchor_attrs,
  24     }
  25
  [end of website/thaliawebsite/templatetags/grid_item.py]
  [start of website/partners/templatetags/partner_cards.py]
  1 from django import template
  2 from django.conf import settings
  3 from django.template.defaultfilters import striptags, truncatechars
  4 
  5 from thaliawebsite.templatetags.bleach_tags import bleach
  6 from thaliawebsite.templatetags.grid_item import grid_item
  7 from utils.media.services import get_thumbnail_url
  8 from partners.models import Vacancy
  9 
  10 register = template.Library()
  11 
  12 
  13 @register.inclusion_tag("includes/grid_item.html")
  14 def partner_card(partner):
  15     """Return grid item showing partner."""
  16     image_url = ""
  17     if partner.logo:
  18         image_url = get_thumbnail_url(
  19             partner.logo, settings.THUMBNAIL_SIZES["medium"], fit=False
  20         )
  21 
  22     meta_text = truncatechars(bleach(striptags(partner.company_profile)), 80)
  23 
  24     return grid_item(
  25         title=partner.name,
  26         meta_text='<p class="px-2 d-none d-md-block">{}</p>'.format(meta_text),
  27         url=partner.get_absolute_url,
  28         image_url=image_url,
  29         class_name="partner-card contain-logo",
  30     )
  31 
  32 
  33 @register.inclusion_tag("includes/grid_item.html")
  34 def partner_image_card(image):
  35     """Return grid item showing partner image."""
  36     class_name = "partner-image-card"
  37     image_url = get_thumbnail_url(image, settings.THUMBNAIL_SIZES["medium"])
  38 
  39     return grid_item(
  40         title="",
  41         url=get_thumbnail_url(image, settings.THUMBNAIL_SIZES["large"], fit=False),
  42         image_url=image_url,
  43         class_name=class_name,
  44         anchor_attrs='data-fancybox="gallery"',
  45     )
  46 
  47 
  48 @register.inclusion_tag("partners/vacancy_card.html")
  49 def vacancy_card(vacancy):
  50     """Return grid item showing vacancy."""
  51     image_url = None
  52     if vacancy.get_company_logo():
  53         image_url = get_thumbnail_url(
  54             vacancy.get_company_logo(), settings.THUMBNAIL_SIZES["medium"], fit=False
  55         )
  56 
  57     description = truncatechars(bleach(striptags(vacancy.description)), 300)
  58     extra_class = "external-vacancy"
  59     url = "#vacancy-{}".format(vacancy.id)
  60     keywords = vacancy.keywords.split(",")
  61     location = vacancy.location
  62     if vacancy.partner and vacancy.partner.is_active:
  63         url = "{}#vacancy-{}".format(vacancy.partner.get_absolute_url(), vacancy.id)
  64         extra_class = ""
  65 
  66     return {
  67         "title": vacancy.title,
  68         "company_name": vacancy.get_company_name(),
  69         "image_url": image_url,
  70         "description": description,
  71         "location": location,
  72         "keywords": keywords,
  73         "url": url,
  74         "extra_class": extra_class,
  75     }
  76
  [end of website/partners/templatetags/partner_cards.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/website/partners/templatetags/partner_cards.py b/website/partners/templatetags/partner_cards.py
  --- a/website/partners/templatetags/partner_cards.py
  +++ b/website/partners/templatetags/partner_cards.py
  @@ -27,6 +27,7 @@
           url=partner.get_absolute_url,
           image_url=image_url,
           class_name="partner-card contain-logo",
  +        show_loading_animation=False,
       )
   
   
  diff --git a/website/thaliawebsite/templatetags/grid_item.py b/website/thaliawebsite/templatetags/grid_item.py
  --- a/website/thaliawebsite/templatetags/grid_item.py
  +++ b/website/thaliawebsite/templatetags/grid_item.py
  @@ -12,6 +12,7 @@
       ribbon=None,
       class_name="",
       anchor_attrs="",
  +    show_loading_animation=True,
   ):
       return {
           "title": title,
  @@ -21,4 +22,5 @@
           "ribbon": ribbon,
           "class_name": class_name,
           "anchor_attrs": anchor_attrs,
  +        "show_loading_animation": show_loading_animation,
       }
  
verification_info: {"golden_diff": "diff --git a/website/partners/templatetags/partner_cards.py b/website/partners/templatetags/partner_cards.py\n--- a/website/partners/templatetags/partner_cards.py\n+++ b/website/partners/templatetags/partner_cards.py\n@@ -27,6 +27,7 @@\n         url=partner.get_absolute_url,\n         image_url=image_url,\n         class_name=\"partner-card contain-logo\",\n+        show_loading_animation=False,\n     )\n \n \ndiff --git a/website/thaliawebsite/templatetags/grid_item.py b/website/thaliawebsite/templatetags/grid_item.py\n--- a/website/thaliawebsite/templatetags/grid_item.py\n+++ b/website/thaliawebsite/templatetags/grid_item.py\n@@ -12,6 +12,7 @@\n     ribbon=None,\n     class_name=\"\",\n     anchor_attrs=\"\",\n+    show_loading_animation=True,\n ):\n     return {\n         \"title\": title,\n@@ -21,4 +22,5 @@\n         \"ribbon\": ribbon,\n         \"class_name\": class_name,\n         \"anchor_attrs\": anchor_attrs,\n+        \"show_loading_animation\": show_loading_animation,\n     }\n", "issue": "Partner page partner blocks keep showing the loading animation\n### Describe the bug\r\nPartner page partner blocks keep showing the loading animation.\r\n\r\n### How to reproduce\r\nSteps to reproduce the behaviour:\r\n1. Go to [the Thalia partner page](https://thalia.nu/career/).\r\n2. Scroll down and see the loading animation on the partner blocks.\r\n\r\n### Expected behaviour\r\nThe loading animation should stop when the partners have been loaded.\r\n\n", "before_files": [{"content": "from django import template\n\nregister = template.Library()\n\n\n@register.inclusion_tag(\"includes/grid_item.html\")\ndef grid_item(\n    title=None,\n    meta_text=\"\",\n    url=None,\n    image_url=None,\n    ribbon=None,\n    class_name=\"\",\n    anchor_attrs=\"\",\n):\n    return {\n        \"title\": title,\n        \"url\": url,\n        \"image_url\": image_url,\n        \"meta_text\": meta_text,\n        \"ribbon\": ribbon,\n        \"class_name\": class_name,\n        \"anchor_attrs\": anchor_attrs,\n    }\n", "path": "website/thaliawebsite/templatetags/grid_item.py"}, {"content": "from django import template\nfrom django.conf import settings\nfrom django.template.defaultfilters import striptags, truncatechars\n\nfrom thaliawebsite.templatetags.bleach_tags import bleach\nfrom thaliawebsite.templatetags.grid_item import grid_item\nfrom utils.media.services import get_thumbnail_url\nfrom partners.models import Vacancy\n\nregister = template.Library()\n\n\n@register.inclusion_tag(\"includes/grid_item.html\")\ndef partner_card(partner):\n    \"\"\"Return grid item showing partner.\"\"\"\n    image_url = \"\"\n    if partner.logo:\n        image_url = get_thumbnail_url(\n            partner.logo, settings.THUMBNAIL_SIZES[\"medium\"], fit=False\n        )\n\n    meta_text = truncatechars(bleach(striptags(partner.company_profile)), 80)\n\n    return grid_item(\n        title=partner.name,\n        meta_text='<p class=\"px-2 d-none d-md-block\">{}</p>'.format(meta_text),\n        url=partner.get_absolute_url,\n        image_url=image_url,\n        class_name=\"partner-card contain-logo\",\n    )\n\n\n@register.inclusion_tag(\"includes/grid_item.html\")\ndef partner_image_card(image):\n    \"\"\"Return grid item showing partner image.\"\"\"\n    class_name = \"partner-image-card\"\n    image_url = get_thumbnail_url(image, settings.THUMBNAIL_SIZES[\"medium\"])\n\n    return grid_item(\n        title=\"\",\n        url=get_thumbnail_url(image, settings.THUMBNAIL_SIZES[\"large\"], fit=False),\n        image_url=image_url,\n        class_name=class_name,\n        anchor_attrs='data-fancybox=\"gallery\"',\n    )\n\n\n@register.inclusion_tag(\"partners/vacancy_card.html\")\ndef vacancy_card(vacancy):\n    \"\"\"Return grid item showing vacancy.\"\"\"\n    image_url = None\n    if vacancy.get_company_logo():\n        image_url = get_thumbnail_url(\n            vacancy.get_company_logo(), settings.THUMBNAIL_SIZES[\"medium\"], fit=False\n        )\n\n    description = truncatechars(bleach(striptags(vacancy.description)), 300)\n    extra_class = \"external-vacancy\"\n    url = \"#vacancy-{}\".format(vacancy.id)\n    keywords = vacancy.keywords.split(\",\")\n    location = vacancy.location\n    if vacancy.partner and vacancy.partner.is_active:\n        url = \"{}#vacancy-{}\".format(vacancy.partner.get_absolute_url(), vacancy.id)\n        extra_class = \"\"\n\n    return {\n        \"title\": vacancy.title,\n        \"company_name\": vacancy.get_company_name(),\n        \"image_url\": image_url,\n        \"description\": description,\n        \"location\": location,\n        \"keywords\": keywords,\n        \"url\": url,\n        \"extra_class\": extra_class,\n    }\n", "path": "website/partners/templatetags/partner_cards.py"}]}