Skip to content

'NoneType' object has no attribute 'name' #8

@gurvinderd

Description

@gurvinderd

Everything is working at stage, except i get an error on recommendation page.
Line causing the error :
user_cluster_name =
User.objects.get(username=request.user.username).cluster_set.first().name

'NoneType' object has no attribute 'name'

Request Method: GET
Request URL: http://192.168.99.100:8000/reviews/recommendation/
Django Version: 1.11
Exception Type: AttributeError
Exception Value:
'NoneType' object has no attribute 'name'
Exception Location: /code/reviews/views.py in user_recommendation_list, line 92
Python Executable: /opt/conda/bin/python
Python Version: 3.6.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions