Merge lp:~pskoli93/postorius/list-name-limit into lp:postorius

Proposed by Pavan Koli
Status: Needs review
Proposed branch: lp:~pskoli93/postorius/list-name-limit
Merge into: lp:postorius
Diff against target: 12 lines (+1/-1)
1 file modified
src/postorius/forms.py (+1/-1)
To merge this branch: bzr merge lp:~pskoli93/postorius/list-name-limit
Reviewer Review Type Date Requested Status
Mailman Coders Pending
Review via email: mp+256734@code.launchpad.net

Description of the change

When creating a new list a maximum character limit is necessary for name of the list, here a limit of 100 characters has been proposed to the list name.

A folder corresponding to the list-name@domain is created at the path mailam/var/lists. There is character limit on the name that can be given for path and file(more info- http://stackoverflow.com/a/6571568/3601099, http://unix.stackexchange.com/a/29001).

If we specify a very long name suppose exceeding 150 characters during the creation of the folder an error arises with the makedir() which leads to a HTTP 500 error.

To post a comment you must log in.

Unmerged revisions

245. By pkoli <email address hidden>

Limit on the list name

244. By pkoli <email address hidden>

Main branch merge

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/postorius/forms.py'
2--- src/postorius/forms.py 2015-04-17 21:51:29 +0000
3+++ src/postorius/forms.py 2015-04-18 09:59:54 +0000
4@@ -98,7 +98,7 @@
5 Form fields to add a new list. Languages are hard coded which should
6 be replaced by a REST lookup of available languages.
7 """
8- listname = forms.CharField(
9+ listname = forms.CharField(max_length=100,
10 label=_('List Name'),
11 required=True,
12 error_messages={'required': _('Please enter a name for your list.'),

Subscribers

People subscribed via source and target branches