class MyCustomForm(forms.ModelForm):

    def __init__(self, *args, **kwargs):
        self.request = kwargs.pop('request', None)
super(MyCustomForm, self).__init__(*args, **kwargs)
How do I access the request object or any other variable in a form's clean() method?