If you did for example, use the same key for github and login, anyone could access your public keys on this unauthenticated url:
Besides, there are additional (server-side) safeguards to prevent someone from doing these sorts of mass public key checks using anyone's public key, including (but not limited to) IP whitelisting and port knocking.
It's an another attack vector too though, if you SSH to my server you send me all of your public keys in ~/.ssh by default (or at least the hashes of them), and I can compare them to GitHub to find out your real identify. Github is just making this trivial by needlessly exposing them.