Django request.user and PyUnresolvedReferences

The user object in a django HttpRequest is not recognized by pycharm. I have hundreds of these in my project, each showing a warning.

Is there a way to:

1) Restrict '# noinspection PyUnresolvedReference' to '# noinspection PyUnresolvedReference request.user' only?

2) Apply a noinspection for request.user on a file by file basis (not a class by class basis, a file by file basis)?

3) Fake pycharm into understanding request.user?

I don't want to disable inspections completely, just this one.

1 comment
You may configure it:

Actually, PyCharm understands request has user if AuthenticationMiddleware is installed.

Please sign in to leave a comment.