prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  testing 5024: missing location label
  **URL:** https://meinberlin-dev.liqd.net/projekte/burgerhaushalt-spandau/?mode=list
  **user:** any
  **expected behaviour:** 
  **behaviour:** location label (Bezeichnung des markierten Ortes) is missing
  **important screensize:**
  **device & browser:** 
  **Comment/Question:** maybe we need a smaller char restriction here? it's at 255 now, I wonder if something like 50 should be enough for something displayed as a tag? or continue with ... for longer words?
  
  old list
  <img width="446" alt="Bildschirmfoto 2021-12-21 um 16 35 27" src="https://user-images.githubusercontent.com/35491681/146956690-789f6d02-372c-4877-a4c9-c539b5fc90c3.png">
  
  
  new list
  <img width="446" alt="Bildschirmfoto 2021-12-21 um 16 34 09" src="https://user-images.githubusercontent.com/35491681/146956491-2472f9f2-e90d-4975-88a8-fbe1a7012657.png">
  
  old list with long label
  <img width="656" alt="Bildschirmfoto 2021-12-21 um 16 36 09" src="https://user-images.githubusercontent.com/35491681/146956804-ced5b4b8-0da8-42fc-a17c-901fc86efe9b.png">
  
  
  
  
  
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `meinberlin/apps/budgeting/serializers.py`
  Content:
  ```
  1 from django.contrib.contenttypes.models import ContentType
  2 from rest_framework import serializers
  3 
  4 from adhocracy4.categories.models import Category
  5 from meinberlin.apps.votes.models import TokenVote
  6 
  7 from .models import Proposal
  8 
  9 
  10 class CategoryField(serializers.Field):
  11 
  12     def to_internal_value(self, category):
  13         if category:
  14             return Category.objects.get(pk=category)
  15         else:
  16             return None
  17 
  18     def to_representation(self, category):
  19         return {'id': category.pk, 'name': category.name}
  20 
  21 
  22 class ProposalSerializer(serializers.ModelSerializer):
  23 
  24     creator = serializers.SerializerMethodField()
  25     comment_count = serializers.SerializerMethodField()
  26     positive_rating_count = serializers.SerializerMethodField()
  27     negative_rating_count = serializers.SerializerMethodField()
  28     category = CategoryField()
  29     url = serializers.SerializerMethodField()
  30     moderator_feedback = serializers.SerializerMethodField()
  31     session_token_voted = serializers.SerializerMethodField()
  32 
  33     class Meta:
  34         model = Proposal
  35         fields = ('budget', 'category', 'comment_count', 'created', 'modified',
  36                   'creator', 'is_archived', 'name', 'negative_rating_count',
  37                   'positive_rating_count', 'url', 'pk', 'moderator_feedback',
  38                   'session_token_voted')
  39         read_only_fields = ('budget', 'category', 'comment_count', 'created',
  40                             'modified', 'creator', 'is_archived', 'name',
  41                             'negative_rating_count', 'positive_rating_count',
  42                             'url', 'pk', 'moderator_feedback',
  43                             'session_token_voted')
  44 
  45     def get_creator(self, proposal):
  46         return proposal.creator.username
  47 
  48     def get_comment_count(self, proposal):
  49         if hasattr(proposal, 'comment_count'):
  50             return proposal.comment_count
  51         else:
  52             return 0
  53 
  54     def get_positive_rating_count(self, proposal):
  55         if hasattr(proposal, 'positive_rating_count'):
  56             return proposal.positive_rating_count
  57         else:
  58             return 0
  59 
  60     def get_negative_rating_count(self, proposal):
  61         if hasattr(proposal, 'negative_rating_count'):
  62             return proposal.negative_rating_count
  63         else:
  64             return 0
  65 
  66     def get_url(self, proposal):
  67         return proposal.get_absolute_url()
  68 
  69     def get_moderator_feedback(self, proposal):
  70         if hasattr(proposal, 'moderator_feedback'):
  71             return (proposal.moderator_feedback,
  72                     proposal.get_moderator_feedback_display())
  73         else:
  74             return None
  75 
  76     def get_session_token_voted(self, proposal):
  77         """Serialize if proposal has been voted.
  78 
  79         Returns bool that indicates whether the proposal has
  80         been voted with the token in the current session
  81         """
  82         if 'request' in self.context:
  83             if 'voting_token' in self.context['request'].session:
  84                 vote = TokenVote.objects.filter(
  85                     token__pk=self.context['request'].session['voting_token'],
  86                     content_type=ContentType.objects.get_for_model(
  87                         proposal.__class__),
  88                     object_pk=proposal.pk
  89                 )
  90                 if vote.exists():
  91                     return True
  92 
  93         return False
  94
  ```
  --- END FILES ---
  
  Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.
  
  Here is an example:
  
  ```diff
  diff --git a/examples/server_async.py b/examples/server_async.py
  --- a/examples/server_async.py
  +++ b/examples/server_async.py
  @@ -313,4 +313,4 @@
   
   
   if __name__ == "__main__":
  -    asyncio.run(run_async_server("."), debug=True)
  +    asyncio.run(run_async_server(), debug=True)
  diff --git a/examples/server_sync.py b/examples/server_sync.py
  --- a/examples/server_sync.py
  +++ b/examples/server_sync.py
  @@ -313,5 +313,5 @@
   
   
   if __name__ == "__main__":
  -    server = run_sync_server(".")
  +    server = run_sync_server()
       server.shutdown()
  
  ```
  
golden_diff: diff --git a/meinberlin/apps/budgeting/serializers.py b/meinberlin/apps/budgeting/serializers.py
  --- a/meinberlin/apps/budgeting/serializers.py
  +++ b/meinberlin/apps/budgeting/serializers.py
  @@ -35,12 +35,12 @@
           fields = ('budget', 'category', 'comment_count', 'created', 'modified',
                     'creator', 'is_archived', 'name', 'negative_rating_count',
                     'positive_rating_count', 'url', 'pk', 'moderator_feedback',
  -                  'session_token_voted')
  +                  'point_label', 'session_token_voted')
           read_only_fields = ('budget', 'category', 'comment_count', 'created',
                               'modified', 'creator', 'is_archived', 'name',
                               'negative_rating_count', 'positive_rating_count',
                               'url', 'pk', 'moderator_feedback',
  -                            'session_token_voted')
  +                            'point_label', 'session_token_voted')
   
       def get_creator(self, proposal):
           return proposal.creator.username
  @@ -73,6 +73,12 @@
           else:
               return None
   
  +    def get_point_label(self, proposal):
  +        if hasattr(proposal, 'point_label'):
  +            return (proposal.point_label)
  +        else:
  +            return None
  +
       def get_session_token_voted(self, proposal):
           """Serialize if proposal has been voted.
  
verification_info: {"golden_diff": "diff --git a/meinberlin/apps/budgeting/serializers.py b/meinberlin/apps/budgeting/serializers.py\n--- a/meinberlin/apps/budgeting/serializers.py\n+++ b/meinberlin/apps/budgeting/serializers.py\n@@ -35,12 +35,12 @@\n         fields = ('budget', 'category', 'comment_count', 'created', 'modified',\n                   'creator', 'is_archived', 'name', 'negative_rating_count',\n                   'positive_rating_count', 'url', 'pk', 'moderator_feedback',\n-                  'session_token_voted')\n+                  'point_label', 'session_token_voted')\n         read_only_fields = ('budget', 'category', 'comment_count', 'created',\n                             'modified', 'creator', 'is_archived', 'name',\n                             'negative_rating_count', 'positive_rating_count',\n                             'url', 'pk', 'moderator_feedback',\n-                            'session_token_voted')\n+                            'point_label', 'session_token_voted')\n \n     def get_creator(self, proposal):\n         return proposal.creator.username\n@@ -73,6 +73,12 @@\n         else:\n             return None\n \n+    def get_point_label(self, proposal):\n+        if hasattr(proposal, 'point_label'):\n+            return (proposal.point_label)\n+        else:\n+            return None\n+\n     def get_session_token_voted(self, proposal):\n         \"\"\"Serialize if proposal has been voted.\n", "issue": "testing 5024: missing location label\n**URL:** https://meinberlin-dev.liqd.net/projekte/burgerhaushalt-spandau/?mode=list\r\n**user:** any\r\n**expected behaviour:** \r\n**behaviour:** location label (Bezeichnung des markierten Ortes) is missing\r\n**important screensize:**\r\n**device & browser:** \r\n**Comment/Question:** maybe we need a smaller char restriction here? it's at 255 now, I wonder if something like 50 should be enough for something displayed as a tag? or continue with ... for longer words?\r\n\r\nold list\r\n<img width=\"446\" alt=\"Bildschirmfoto 2021-12-21 um 16 35 27\" src=\"https://user-images.githubusercontent.com/35491681/146956690-789f6d02-372c-4877-a4c9-c539b5fc90c3.png\">\r\n\r\n\r\nnew list\r\n<img width=\"446\" alt=\"Bildschirmfoto 2021-12-21 um 16 34 09\" src=\"https://user-images.githubusercontent.com/35491681/146956491-2472f9f2-e90d-4975-88a8-fbe1a7012657.png\">\r\n\r\nold list with long label\r\n<img width=\"656\" alt=\"Bildschirmfoto 2021-12-21 um 16 36 09\" src=\"https://user-images.githubusercontent.com/35491681/146956804-ced5b4b8-0da8-42fc-a17c-901fc86efe9b.png\">\r\n\r\n\r\n\r\n\r\n\n", "before_files": [{"content": "from django.contrib.contenttypes.models import ContentType\nfrom rest_framework import serializers\n\nfrom adhocracy4.categories.models import Category\nfrom meinberlin.apps.votes.models import TokenVote\n\nfrom .models import Proposal\n\n\nclass CategoryField(serializers.Field):\n\n    def to_internal_value(self, category):\n        if category:\n            return Category.objects.get(pk=category)\n        else:\n            return None\n\n    def to_representation(self, category):\n        return {'id': category.pk, 'name': category.name}\n\n\nclass ProposalSerializer(serializers.ModelSerializer):\n\n    creator = serializers.SerializerMethodField()\n    comment_count = serializers.SerializerMethodField()\n    positive_rating_count = serializers.SerializerMethodField()\n    negative_rating_count = serializers.SerializerMethodField()\n    category = CategoryField()\n    url = serializers.SerializerMethodField()\n    moderator_feedback = serializers.SerializerMethodField()\n    session_token_voted = serializers.SerializerMethodField()\n\n    class Meta:\n        model = Proposal\n        fields = ('budget', 'category', 'comment_count', 'created', 'modified',\n                  'creator', 'is_archived', 'name', 'negative_rating_count',\n                  'positive_rating_count', 'url', 'pk', 'moderator_feedback',\n                  'session_token_voted')\n        read_only_fields = ('budget', 'category', 'comment_count', 'created',\n                            'modified', 'creator', 'is_archived', 'name',\n                            'negative_rating_count', 'positive_rating_count',\n                            'url', 'pk', 'moderator_feedback',\n                            'session_token_voted')\n\n    def get_creator(self, proposal):\n        return proposal.creator.username\n\n    def get_comment_count(self, proposal):\n        if hasattr(proposal, 'comment_count'):\n            return proposal.comment_count\n        else:\n            return 0\n\n    def get_positive_rating_count(self, proposal):\n        if hasattr(proposal, 'positive_rating_count'):\n            return proposal.positive_rating_count\n        else:\n            return 0\n\n    def get_negative_rating_count(self, proposal):\n        if hasattr(proposal, 'negative_rating_count'):\n            return proposal.negative_rating_count\n        else:\n            return 0\n\n    def get_url(self, proposal):\n        return proposal.get_absolute_url()\n\n    def get_moderator_feedback(self, proposal):\n        if hasattr(proposal, 'moderator_feedback'):\n            return (proposal.moderator_feedback,\n                    proposal.get_moderator_feedback_display())\n        else:\n            return None\n\n    def get_session_token_voted(self, proposal):\n        \"\"\"Serialize if proposal has been voted.\n\n        Returns bool that indicates whether the proposal has\n        been voted with the token in the current session\n        \"\"\"\n        if 'request' in self.context:\n            if 'voting_token' in self.context['request'].session:\n                vote = TokenVote.objects.filter(\n                    token__pk=self.context['request'].session['voting_token'],\n                    content_type=ContentType.objects.get_for_model(\n                        proposal.__class__),\n                    object_pk=proposal.pk\n                )\n                if vote.exists():\n                    return True\n\n        return False\n", "path": "meinberlin/apps/budgeting/serializers.py"}], "after_files": [{"content": "from django.contrib.contenttypes.models import ContentType\nfrom rest_framework import serializers\n\nfrom adhocracy4.categories.models import Category\nfrom meinberlin.apps.votes.models import TokenVote\n\nfrom .models import Proposal\n\n\nclass CategoryField(serializers.Field):\n\n    def to_internal_value(self, category):\n        if category:\n            return Category.objects.get(pk=category)\n        else:\n            return None\n\n    def to_representation(self, category):\n        return {'id': category.pk, 'name': category.name}\n\n\nclass ProposalSerializer(serializers.ModelSerializer):\n\n    creator = serializers.SerializerMethodField()\n    comment_count = serializers.SerializerMethodField()\n    positive_rating_count = serializers.SerializerMethodField()\n    negative_rating_count = serializers.SerializerMethodField()\n    category = CategoryField()\n    url = serializers.SerializerMethodField()\n    moderator_feedback = serializers.SerializerMethodField()\n    session_token_voted = serializers.SerializerMethodField()\n\n    class Meta:\n        model = Proposal\n        fields = ('budget', 'category', 'comment_count', 'created', 'modified',\n                  'creator', 'is_archived', 'name', 'negative_rating_count',\n                  'positive_rating_count', 'url', 'pk', 'moderator_feedback',\n                  'point_label', 'session_token_voted')\n        read_only_fields = ('budget', 'category', 'comment_count', 'created',\n                            'modified', 'creator', 'is_archived', 'name',\n                            'negative_rating_count', 'positive_rating_count',\n                            'url', 'pk', 'moderator_feedback',\n                            'point_label', 'session_token_voted')\n\n    def get_creator(self, proposal):\n        return proposal.creator.username\n\n    def get_comment_count(self, proposal):\n        if hasattr(proposal, 'comment_count'):\n            return proposal.comment_count\n        else:\n            return 0\n\n    def get_positive_rating_count(self, proposal):\n        if hasattr(proposal, 'positive_rating_count'):\n            return proposal.positive_rating_count\n        else:\n            return 0\n\n    def get_negative_rating_count(self, proposal):\n        if hasattr(proposal, 'negative_rating_count'):\n            return proposal.negative_rating_count\n        else:\n            return 0\n\n    def get_url(self, proposal):\n        return proposal.get_absolute_url()\n\n    def get_moderator_feedback(self, proposal):\n        if hasattr(proposal, 'moderator_feedback'):\n            return (proposal.moderator_feedback,\n                    proposal.get_moderator_feedback_display())\n        else:\n            return None\n\n    def get_point_label(self, proposal):\n        if hasattr(proposal, 'point_label'):\n            return (proposal.point_label)\n        else:\n            return None\n\n    def get_session_token_voted(self, proposal):\n        \"\"\"Serialize if proposal has been voted.\n\n        Returns bool that indicates whether the proposal has\n        been voted with the token in the current session\n        \"\"\"\n        if 'request' in self.context:\n            if 'voting_token' in self.context['request'].session:\n                vote = TokenVote.objects.filter(\n                    token__pk=self.context['request'].session['voting_token'],\n                    content_type=ContentType.objects.get_for_model(\n                        proposal.__class__),\n                    object_pk=proposal.pk\n                )\n                if vote.exists():\n                    return True\n\n        return False\n", "path": "meinberlin/apps/budgeting/serializers.py"}]}