Skip to content

'WSGIRequest' object has no attribute 'user' error in enterprise code #37995

@robrap

Description

@robrap

This line of enterprise code, is resulting in the error: builtins.AttributeError: 'WSGIRequest' object has no attribute 'user'.

I believe this just needs some simple exception handling to provide the same treatment as is done for an anonymous (not logged in) user, without raising an exception.

  • This should be a relatively quick fix.
  • This may not lead to end user problems, because it may just be happening during 404 processing, but I'm uncertain. It definitely muddies the 404 error details and observability.

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedReady to be picked up by anyone in the community

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions