> why not allow developers to restrict access localhost?
Ads and tracking, obviously (https://localmess.github.io/)
All these changes Google is doing to Android aren't for you as the user, they are to protect their business interests from the user.