internlm/SWE-Fixer-Train-110K huggingface dataset:
Repository: liqd/a4-meinberlin

Issue:
DataError: value too long for type character varying(100)
Sentry Issue: [MEINBERLIN-DEV-2Z](https://sentry.liqd.net/organizations/liqd/issues/1357/?referrer=github_integration)

```
StringDataRightTruncation: value too long for type character varying(100)

  File "django/db/backends/utils.py", line 84, in _execute
    return self.cursor.execute(sql, params)

DataError: value too long for type character varying(100)

(29 additional frame(s) were not displayed)
...
  File "django/db/backends/utils.py", line 67, in execute
    return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  File "django/db/backends/utils.py", line 76, in _execute_with_wrappers
    return executor(sql, params, many, context)
  File "django/db/backends/utils.py", line 84, in _execute
    return self.cursor.execute(sql, params)
  File "django/db/utils.py", line 89, in __exit__
    raise dj_exc_value.with_traceback(traceback) from exc_value
  File "django/db/backends/utils.py", line 84, in _execute
    return self.cursor.execute(sql, params)

Internal Server Error: /api/organisations/1/bplan/
```


Discussion:

Resolving patch:
diff --git a/meinberlin/apps/bplan/serializers.py b/meinberlin/apps/bplan/serializers.py
--- a/meinberlin/apps/bplan/serializers.py
+++ b/meinberlin/apps/bplan/serializers.py
@@ -36,11 +36,18 @@ class BplanSerializer(serializers.ModelSerializer):
     # make write_only for consistency  reasons
     start_date = serializers.DateTimeField(write_only=True)
     end_date = serializers.DateTimeField(write_only=True)
-    image_url = serializers.URLField(required=False, write_only=True)
-    image_copyright = serializers.CharField(required=False, write_only=True,
-                                            source='tile_image_copyright',
-                                            allow_blank=True,
-                                            max_length=120)
+    image_url = serializers.URLField(
+        required=False,
+        write_only=True,
+        max_length=(project_models.Project._meta.
+                    get_field('tile_image').max_length))
+    image_copyright = serializers.CharField(
+        required=False,
+        write_only=True,
+        source='tile_image_copyright',
+        allow_blank=True,
+        max_length=(project_models.Project._meta.
+                    get_field('tile_image_copyright').max_length))
     embed_code = serializers.SerializerMethodField()
 
     class Meta:


Test patch:
Repository: liqd/a4-meinberlin

Issue:
testing 4293: change wording for template
**URL:** module template in dashboard
**user:** initiator
**expected behaviour:** correct template description
**behaviour:** needs to be adapted
**important screensize:**
**device & browser:** 
**Comment/Question:** 

change wording from:
Die Teilnehmenden können auf eine oder mehrere Fragen mit vordefinierten Antwortmöglichkeiten antworten und die Umfrage kommentieren.

to 
Die Teilnehmenden können auf offene und Multiple-Choice-Fragen antworten und die Umfrage kommentieren.

Participants can answer to open and multiple choice questions and comment on the poll. 





Discussion:
better english i think would be:
'Participants can answer open and multiple choice questions and can comment on the poll'
@phillimorland great, thanks!

Resolving patch:
diff --git a/meinberlin/apps/dashboard/blueprints.py b/meinberlin/apps/dashboard/blueprints.py
--- a/meinberlin/apps/dashboard/blueprints.py
+++ b/meinberlin/apps/dashboard/blueprints.py
@@ -153,8 +153,8 @@
      ProjectBlueprint(
          title=_('Poll'),
          description=_(
-             'Participants can answer one or more questions with predefined '
-             'choices and comment on the poll.'
+             'Participants can answer open and multiple choice questions '
+             'and can comment on the poll'
          ),
          content=[
              poll_phases.VotingPhase(),


Test patch:
Repository: liqd/a4-meinberlin

Issue:
testing 4543: changing picture size in CKeditor doesn't effect frontend
**URL:** https://meinberlin-dev.liqd.net/vorhaben/2021-00074/
**user:** any
**expected behaviour:** if I change the size of my picture in CKeditor the size is also changed in frontend
**behaviour:** picture always has the same size, changes are not saved
**important screensize:**
**device & browser:** chrome, big sur
**Comment/Question:** Is that on purpose because we want the plan to look nice and not have screwed up pictures? I think we should allow it as we also do that for projects.

Screenshot?



Discussion:
@khamui this still does not work. Am I missing something?
@CarolingerSeilchenspringer sorry my bad. I linked this issue, but it was not solved by the PR back then.

@fuzzylogic2000 @Rineee @phillimorland @sabinammm : I investigated and figured out that the `<img>'s ` attributes `width` and `height` are saved to backend (POST), but in case of plans the GET does not return the image with those set attributes. Maybe someone can pair with me having a look how to check this?
@phillimorland thats the issue i was talking about in standup.

Resolving patch:
diff --git a/meinberlin/apps/plans/models.py b/meinberlin/apps/plans/models.py
--- a/meinberlin/apps/plans/models.py
+++ b/meinberlin/apps/plans/models.py
@@ -214,7 +214,8 @@ def get_absolute_url(self):
                                    year=self.created.year))
 
     def save(self, *args, **kwargs):
-        self.description = transforms.clean_html_field(self.description)
+        self.description = transforms.clean_html_field(
+            self.description, 'collapsible-image-editor')
         super().save(*args, **kwargs)
 
     def _get_group(self, user, organisation):


Test patch:
Repository: liqd/a4-meinberlin

Issue:
users should not be able to embed video in their idea
**URL:** https://meinberlin-stage.liqd.net/mapideas/create/module/brainstorming-mit-kartenfunktion-36/
**user:** registered user
**expected behaviour:** should not be able to embed video
**behaviour:** is able to embed video in idea form
**important screensize:**
**device & browser:** 
**Comment/Question:** we should not allow this also because it may look crap in frontend if also a picture has been uploaded. Don't know where this came from but it is not on prod.

Screenshot?
![Bildschirmfoto 2021-09-21 um 16 03 08](https://user-images.githubusercontent.com/35491681/134185645-74a47fcb-935c-4f83-8689-1c75f1c0e095.png)

![Bildschirmfoto 2021-09-21 um 16 05 47](https://user-images.githubusercontent.com/35491681/134185721-56575fa0-2c77-4de8-9ae6-f4a2b5b70115.png)





Discussion:

Resolving patch:
diff --git a/meinberlin/config/settings/base.py b/meinberlin/config/settings/base.py
--- a/meinberlin/config/settings/base.py
+++ b/meinberlin/config/settings/base.py
@@ -312,7 +312,6 @@
             ['Bold', 'Italic', 'Underline'],
             ['NumberedList', 'BulletedList'],
             ['Link', 'Unlink'],
-            ['Embed', 'EmbedBase']
         ],
         'removePlugins': 'stylesheetparser',
         'extraAllowedContent': 'iframe[*]',


Test patch:
Repository: liqd/a4-meinberlin

Issue:
In Bplans required field (start-date & end-date) for publication is not marked as such
**URL:** https://meinberlin-dev.liqd.net/dashboard/projects/sabinas-bebauungsplan/bplan/
**user:** A Bplan initiator
**expected behaviour:** As a Bplan initiator, I want the form to tell me which fields are required so that I can publish
**behaviour:** Because the start- and enddate are not marked as required for publication, it's unclear that not filling these in is hindering publication
**important screensize:** any
**device & browser:** ubuntu chrome
**Comment/Question:**
These are just missing red the exclamation point icons. It's a simple fix in forms.py

Screenshot?
![image](https://user-images.githubusercontent.com/17978375/143887527-8add272b-af23-41d9-8fe6-08a5ae7f85d6.png)




Discussion:

Resolving patch:
diff --git a/meinberlin/apps/bplan/forms.py b/meinberlin/apps/bplan/forms.py
--- a/meinberlin/apps/bplan/forms.py
+++ b/meinberlin/apps/bplan/forms.py
@@ -28,7 +28,8 @@ class Meta:
                   'tile_image_copyright', 'is_archived', 'office_worker_email',
                   'start_date', 'end_date']
         required_for_project_publish = ['name', 'url', 'description',
-                                        'office_worker_email']
+                                        'office_worker_email',
+                                        'start_date', 'end_date']
 
     def __init__(self, *args, **kwargs):
         super().__init__(*args, **kwargs)


Test patch:
Repository: liqd/a4-meinberlin

Issue:
dashboard: cannot enter livestream
**URL:** https://meinberlin-dev.liqd.net/dashboard/modules/interactive-event/livestream/
**user:** initiator
**expected behaviour:** I can enter a livestream in information or result tab or in an event or in interactive event module 
**behaviour:** get an error (see screenshot)
**important screensize:**
**device & browser:** mac big sur and monterry on all major browser, also edge
**Comment/Question:** 

Screenshot?
<img width="639" alt="Bildschirmfoto 2021-12-16 um 12 05 48" src="https://user-images.githubusercontent.com/35491681/146363784-ea795c03-6812-4cb1-82f0-60132cd88a72.png">




Discussion:
same as here https://github.com/liqd/adhocracy-plus/issues/1546
@CarolingerSeilchenspringer can you enter video embed for any of the tabs? we also have it in info tab
@phillimorland I tried in infotab, result tab, event and interactive event. None of them worked.

Resolving patch:
diff --git a/meinberlin/config/settings/base.py b/meinberlin/config/settings/base.py
--- a/meinberlin/config/settings/base.py
+++ b/meinberlin/config/settings/base.py
@@ -323,8 +323,8 @@
         'removePlugins': 'stylesheetparser',
         'extraAllowedContent': 'iframe[*]',
         'extraPlugins': ','.join(['embed', 'embedbase']),
-        'embed_provider':
-            '//ckeditor.iframe.ly/api/oembed?url={url}&callback={callback}',
+        'providerUrl':
+            'https//ckeditor.iframe.ly/api/oembed?url={url}&callback={callback}',
     },
     'image-editor': {
         'width': '100%',


Test patch:
Repository: liqd/a4-meinberlin

Issue:
testing 5024: order of filter 
**URL:** https://meinberlin-dev.liqd.net/projekte/burgerhaushalt-spandau/?mode=list
**user:** any
**expected behaviour:** 
**behaviour:** 
**important screensize:**
**device & browser:** 
**Comment/Question:** the order of the filter was 1) category 2) archive. It should stay this way but as we will touch the filter again later we can also do it then but need to remember. So if easy maybe change now?

Screenshot?
<img width="490" alt="Bildschirmfoto 2021-12-21 um 16 25 15" src="https://user-images.githubusercontent.com/35491681/146955180-11799600-c739-4d17-8f84-7581b57a861b.png">




Discussion:

Resolving patch:
diff --git a/meinberlin/apps/budgeting/api.py b/meinberlin/apps/budgeting/api.py
--- a/meinberlin/apps/budgeting/api.py
+++ b/meinberlin/apps/budgeting/api.py
@@ -56,16 +56,6 @@ def list(self, request, *args, **kwargs):
             'default': '-created',
         }
 
-        filters['is_archived'] = {
-            'label': _('Archived'),
-            'choices': [
-                ('', _('All')),
-                ('false', _('No')),
-                ('true', _('Yes')),
-            ],
-            'default': 'false',
-        }
-
         categories = Category.objects.filter(
             module=self.module
         )
@@ -87,6 +77,16 @@ def list(self, request, *args, **kwargs):
             if has_icons(self.module):
                 filters['category']['icons'] = category_icons
 
+        filters['is_archived'] = {
+            'label': _('Archived'),
+            'choices': [
+                ('', _('All')),
+                ('false', _('No')),
+                ('true', _('Yes')),
+            ],
+            'default': 'false',
+        }
+
         response = super().list(request, args, kwargs)
         response.data['filters'] = filters
         return response


Test patch:
Repository: liqd/a4-meinberlin

Issue:
dashboard: cannot enter livestream
**URL:** https://meinberlin-dev.liqd.net/dashboard/modules/interactive-event/livestream/
**user:** initiator
**expected behaviour:** I can enter a livestream in information or result tab or in an event or in interactive event module 
**behaviour:** get an error (see screenshot)
**important screensize:**
**device & browser:** mac big sur and monterry on all major browser, also edge
**Comment/Question:** 

Screenshot?
<img width="639" alt="Bildschirmfoto 2021-12-16 um 12 05 48" src="https://user-images.githubusercontent.com/35491681/146363784-ea795c03-6812-4cb1-82f0-60132cd88a72.png">




Discussion:
same as here https://github.com/liqd/adhocracy-plus/issues/1546
@CarolingerSeilchenspringer can you enter video embed for any of the tabs? we also have it in info tab
@phillimorland I tried in infotab, result tab, event and interactive event. None of them worked.

Resolving patch:
diff --git a/meinberlin/config/settings/base.py b/meinberlin/config/settings/base.py
--- a/meinberlin/config/settings/base.py
+++ b/meinberlin/config/settings/base.py
@@ -323,8 +323,8 @@
         'removePlugins': 'stylesheetparser',
         'extraAllowedContent': 'iframe[*]',
         'extraPlugins': ','.join(['embed', 'embedbase']),
-        'providerUrl':
-            'https//ckeditor.iframe.ly/api/oembed?url={url}&callback={callback}',
+        'embed_provider':
+            '//ckeditor.iframe.ly/api/oembed?url={url}&callback={callback}',
     },
     'image-editor': {
         'width': '100%',


Test patch:
Repository: liqd/a4-meinberlin

Issue:
user front end: make username in idea list bold
**URL:** https://meinberlin-dev.liqd.net/projekte/brainstorming-2/
**user:** any
**expected behaviour:** 
**behaviour:** better distinguish username and date of creation/editing. e.g. by making the username bolt as we do in idea detail view
**important screensize:**
**device & browser:** 
**Comment/Question:** 



Screenshot?
<img width="639" alt="Bildschirmfoto 2021-12-16 um 12 14 35" src="https://user-images.githubusercontent.com/35491681/146361740-cf6915cf-bef4-497d-83f5-6e8cf1154ddb.png">


testing 5024: filter bar above list on smaller screens
**URL:** https://meinberlin-dev.liqd.net/projekte/burgerhaushalt-spandau/?mode=list
**user:** any
**expected behaviour:**
**behaviour:** on screens smaller than 1200: list/map switch, sorting and filter don't look the same as old list, although old list also doesn't look good between around 850 and 1100 
**important screensize:**
**device & browser:** 
**Comment/Question:** or should we change that when touching the filter again? not sure though when that will be so maybe now make it look good?

Screenshot?

<img width="439" alt="Bildschirmfoto 2021-12-20 um 18 03 19" src="https://user-images.githubusercontent.com/35491681/146957441-4e6c4f98-609e-4d85-a21b-a7d2b6964909.png">




Discussion:
Is this a question to discuss and for @mcastro-lqd to decide or should we just do it?
@CarolingerSeilchenspringer I just kept the current version. But here you go: https://zpl.io/25mrrOn
thanks @mcastro-lqd and after reading @fuzzylogic2000 s question on issue #4098 I guess this would also be true for the other idea/proposal list.


Resolving patch:
diff --git a/meinberlin/apps/budgeting/api.py b/meinberlin/apps/budgeting/api.py
--- a/meinberlin/apps/budgeting/api.py
+++ b/meinberlin/apps/budgeting/api.py
@@ -45,17 +45,6 @@ def list(self, request, *args, **kwargs):
         """
         filters = {}
 
-        ordering_choices = [('-created', _('Most recent')), ]
-        if self.module.has_feature('rate', Proposal):
-            ordering_choices += ('-positive_rating_count', _('Most popular')),
-        ordering_choices += ('-comment_count', _('Most commented')),
-
-        filters['ordering'] = {
-            'label': _('Ordering'),
-            'choices': ordering_choices,
-            'default': '-created',
-        }
-
         categories = Category.objects.filter(
             module=self.module
         )
@@ -87,6 +76,17 @@ def list(self, request, *args, **kwargs):
             'default': 'false',
         }
 
+        ordering_choices = [('-created', _('Most recent')), ]
+        if self.module.has_feature('rate', Proposal):
+            ordering_choices += ('-positive_rating_count', _('Most popular')),
+        ordering_choices += ('-comment_count', _('Most commented')),
+
+        filters['ordering'] = {
+            'label': _('Ordering'),
+            'choices': ordering_choices,
+            'default': '-created',
+        }
+
         response = super().list(request, args, kwargs)
         response.data['filters'] = filters
         return response


Test patch:
Repository: liqd/a4-meinberlin

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">







Discussion:
While it does not really belong in here @CarolingerSeilchenspringer Just tell us, what you want changed for the label. So, if you want
1. a shorter char count in the field - existing long place names will be cut off
or
2. want the label cut off after come chars and if yes, where exactly (list and detail?)
and then we will just do it together with displaying in the react list
@fuzzylogic2000 I will write a story about shortening the label as this is also true for non react list such as the one in brainstorming/idea collection. So to close this issue: just show the label in the new react list.

Resolving patch:
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 @@ class Meta:
         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 @@ def get_moderator_feedback(self, proposal):
         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.
 


Test patch:
Repository: liqd/a4-meinberlin

Issue:
plan detail: when participation explanation has default text, the whole box shouldn't be shown
**URL:** 
**user:** 
**expected behaviour:** 
**behaviour:** Only the explanation is not shwon when it has the default text
**important screensize:**
**device & browser:** 
**Comment/Question:** @CarolingerSeilchenspringer said yesterday, that the whole box should be gone when the explanation has the default.

Screenshot?



Discussion:

Resolving patch:
diff --git a/meinberlin/apps/plans/migrations/0054_alter_plan_participation_explanation.py b/meinberlin/apps/plans/migrations/0054_alter_plan_participation_explanation.py
new file mode 100644
--- /dev/null
+++ b/meinberlin/apps/plans/migrations/0054_alter_plan_participation_explanation.py
@@ -0,0 +1,18 @@
+# Generated by Django 3.2.12 on 2022-03-03 12:30
+
+from django.db import migrations, models
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+        ('meinberlin_plans', '0053_plan_participation_explanation'),
+    ]
+
+    operations = [
+        migrations.AlterField(
+            model_name='plan',
+            name='participation_explanation',
+            field=models.TextField(help_text='Justify your selection. The justification appears below the description of the project.', max_length=4000, verbose_name='Participation explanation'),
+        ),
+    ]
diff --git a/meinberlin/apps/plans/models.py b/meinberlin/apps/plans/models.py
--- a/meinberlin/apps/plans/models.py
+++ b/meinberlin/apps/plans/models.py
@@ -156,7 +156,6 @@ class Plan(ProjectContactDetailMixin, UserGeneratedContentModel):
     )
     participation_explanation = models.TextField(
         verbose_name=_('Participation explanation'),
-        default='Bitte Begründung einfügen',
         max_length=4000,
         help_text=_('Justify your selection. '
                     'The justification appears '


Test patch:
Repository: liqd/a4-meinberlin

Issue:
Password reset attempt for non-existant user causes 500 and sentry error
**URL:** 
Sentry error:https://sentry.liqd.net/organizations/liqd/issues/1976/?environment=production&project=5&referrer=alert_email
DEV: https://meinberlin-dev.liqd.net/accounts/password/reset/
STAGE: https://meinberlin-stage.liqd.net/accounts/password/reset/
**user:** unregistered
**expected behaviour:** I get a page that tells me to register or an error that my account does not exist
**behaviour:** I get a 500 error and a sentry error
**important screensize:** any
**device & browser:** any
**Comment/Question:** 
in a+, this triggers a simple error on the same page. Can we implement this here as well?
Screenshot?
**On meinBerlin:**
![image](https://user-images.githubusercontent.com/17978375/159440299-08a805c6-dbac-4c39-9ec5-ee79f7800b3c.png)

**On a+:**
![image](https://user-images.githubusercontent.com/17978375/159440105-910333b0-8912-4ccc-a865-e4dbaa9aae19.png)



Discussion:

Resolving patch:
diff --git a/meinberlin/config/settings/base.py b/meinberlin/config/settings/base.py
--- a/meinberlin/config/settings/base.py
+++ b/meinberlin/config/settings/base.py
@@ -283,6 +283,7 @@
 ACCOUNT_LOGIN_ON_EMAIL_CONFIRMATION = True
 ACCOUNT_LOGIN_ON_PASSWORD_RESET = True
 ACCOUNT_USERNAME_REQUIRED = True
+ACCOUNT_PREVENT_ENUMERATION = True
 SOCIALACCOUNT_AUTO_SIGNUP = False
 SOCIALACCOUNT_EMAIL_VERIFICATION = 'none'
 SOCIALACCOUNT_FORMS = {


Test patch: