The current implementation of the Request class provided by sanic has a __repr__ method that performs an unnecessary None check on method and path and there it is not possible that they can be None. We can remove these condition checks and have a much simpler __repr__ implementation.
__repr__ implementationJust a reminder, don't forget the test.
https://github.com/huge-success/sanic/blob/cea1547e08230b6ad49eb7777fd8db5335382b7a/tests/test_requests.py#L558-L567
Most helpful comment
Just a reminder, don't forget the test.
https://github.com/huge-success/sanic/blob/cea1547e08230b6ad49eb7777fd8db5335382b7a/tests/test_requests.py#L558-L567