AttributeError: module 'restaurants' has no attribute 'pinterest_post'

  1. Describe the issue briefly
    image is successfully getting upload on Facebook but after modification in views.py for posting image on Pinterest it is give attribute error u can check the last line for error:
    Internal Server Error: /qeats/v1/review/share
    Traceback (most recent call last):
    File “/home/crio-user/.local/lib/python3.6/site-packages/django/core/handlers/exception.py”, line 34, in inner
    response = get_response(request)
    File “/home/crio-user/.local/lib/python3.6/site-packages/django/core/handlers/base.py”, line 115, in _get_response
    response = self.process_exception_by_middleware(e, request)
    File “/home/crio-user/.local/lib/python3.6/site-packages/django/core/handlers/base.py”, line 113, in _get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
    File “/home/crio-user/.local/lib/python3.6/site-packages/django/views/decorators/csrf.py”, line 54, in wrapped_view
    return view_func(*args, **kwargs)
    File “/home/crio-user/.local/lib/python3.6/site-packages/django/views/generic/base.py”, line 71, in view
    return self.dispatch(request, *args, **kwargs)
    File “/home/crio-user/.local/lib/python3.6/site-packages/rest_framework/views.py”, line 495, in dispatch
    response = self.handle_exception(exc)
    File “/home/crio-user/.local/lib/python3.6/site-packages/rest_framework/views.py”, line 455, in handle_exception
    self.raise_uncaught_exception(exc)
    File “/home/crio-user/.local/lib/python3.6/site-packages/rest_framework/views.py”, line 492, in dispatch
    response = handler(request, *args, **kwargs)
    File “/home/crio-user/workspace/anirajsoni-mnnit-ME_QEATS_REVIEW_MP/restaurants/views.py”, line 220, in post
    pin = restaurants.pinterest_post.Pinterest()
    AttributeError: module ‘restaurants’ has no attribute ‘pinterest_post’

AND response status at terminal is 500

I have spent 1 hr

please check

You need to complete the TODO’s in views.py file.
The TODO’s are present at the end.

Got my fault
Its corrected now
Thanks

Awesome,
keep going, you are doing great almost there.

Can you give the hint about how to resolve this issue?

Error was coming because i forgot to import the pinterest_post file.