ThetaTau / CMT

App for the Theta Tau Chapter Management Tool
Other
10 stars 3 forks source link

AttributeError: 'ForwardManyToOneDescriptor' object has no attribute 'DoesNotExist' #946

Closed VenturaFranklin closed 2 weeks ago

VenturaFranklin commented 6 months ago

View details in Rollbar: https://app.rollbar.com/a/frank.ventura/fix/item/CMT/570

Traceback (most recent call last):
  File "/home/Venturafranklin/.virtualenvs/thetatauCMT/lib/python3.9/site-packages/django/core/handlers/base.py", line 181, in _get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/usr/local/lib/python3.9/contextlib.py", line 79, in inner
    return func(*args, **kwds)
  File "/home/Venturafranklin/.virtualenvs/thetatauCMT/lib/python3.9/site-packages/django/views/generic/base.py", line 70, in view
    return self.dispatch(request, *args, **kwargs)
  File "/home/Venturafranklin/.virtualenvs/thetatauCMT/lib/python3.9/site-packages/braces/views/_access.py", line 107, in dispatch
    return super(LoginRequiredMixin, self).dispatch(
  File "/home/Venturafranklin/.virtualenvs/thetatauCMT/lib/python3.9/site-packages/django/views/generic/base.py", line 98, in dispatch
    return handler(request, *args, **kwargs)
  File "/home/Venturafranklin/thetatauCMT/thetatauCMT/forms/views.py", line 816, in post
    except UserRoleChange.user.DoesNotExist:
AttributeError: 'ForwardManyToOneDescriptor' object has no attribute 'DoesNotExist'Traceback (most recent call last):
  File "/home/Venturafranklin/thetatauCMT/thetatauCMT/forms/views.py", line 815, in post
    member = form.instance.user
  File "/home/Venturafranklin/.virtualenvs/thetatauCMT/lib/python3.9/site-packages/django/db/models/fields/related_descriptors.py", line 197, in __get__
    raise self.RelatedObjectDoesNotExist(
RelatedObjectDoesNotExist: UserRoleChange has no user.