On all 2.7 versions is currently working like so for me:
example.com/doesnotexist
Messes up the 404
example.com/doesnotexist/doesnotexist
Returns a correct 404
example.com/doesexist/doesnotexist
Returns a correct 404
Is not a theme issue as I’ve checked it on multiple themes now
The problem is that WordPress thinks it’s a category as it’s defaulting to the Archive page by the looks of it