Given this Python class, implementing a Django form, how would you properly break this to meet the PEP8 standards?
class MyForm(forms.Form):
categories = forms.CharField(required=False,
widget=forms.SelectMultiple(choices=CATEGORY_VALUE),
label="Categories")
additional_item_ship_cost = forms.CharField(required=False, max_length=10,
label="Additional Item Ship Cost")
Specifically, the widget= and label= parameters violate the PEP8 rules for line length.
What comes to mind immediately is that I could define the widget and label outside of the class and then use them in the class definition, but that feels very un-pythonic.
I don’t think PEP8 says much about it, but I would simply go with double indentation for the parameters: