I am not going to attempt to explain why this error happens, but I will provide the very illogical solution for making it go away. For the purpose of this article, lets assume that our problematic SharePoint site is located at http://domain.com/site:
1. Add "_layouts/role.aspx" at the end of the URL (so it looks like this: http://domain.com/site/_layouts/role.aspx) to access the Permission Levels settings page for the site.
2. Above the permission levels list click "Edit Permission Levels" to stop inheriting permission levels from the parent site.
3. You will see a pop-up message asking you to confirm, click "OK" to proceed.
4. Once the change is applied, you will see 3 new selections above the permission levels list setting page, click on "Inherit Permission Levels from Parent Web Site" to revert the last change and inherit permission levels again.
5. You will again see a pop-up asking you to confirm the change, click "OK" to proceed:
6. Restart your browser and open the website again (navigate to http://domain.com/site) - you should no longer receive the HTTP 500 error.
As you can see this solution is simply removing the existing Permission Levels inheritance from the parent site (copies them to the subsite that is having a problem), and then inherits them again from the parent site (overwriting the copy created in the previous step). I still have no idea why this works, or why the error happens in the first place - but I did have it happen a couple times now and this is the only way I could find to make it go away. If you have a more scientific explanation - please let me know.