NetBox version
2.11.6
Python version
3.7
Steps to Reproduce
We have multiple Scripts that are running against our Netbox Instance. Some of them are utilizing read only tokens and others read_write tokens. From time to time the following exception occurs:
The request failed with code 500 Internal Server Error {'error': 'Cannot assign <SimpleLazyObject: <django.contrib.auth.models.AnonymousUser object at 0x7fe517e70780>>": "ObjectChange.user'" must be a "User" instance.', 'exception': 'ValueError', 'netbox_version': '2.11.6', 'python_version': '3.7.8'}
After that we have Changes on Objects with the change_user of the read_only token. Maybe there is any kind of race condition or something like that. Does anybody has an idea, how to further investigate this problem?
Expected Behavior
There is no exception and change user are not mixed with read_only user.
Observed Behavior
Exception occurs and change_user is read_only user