Federation doesn’t fix the problem, at least not in its entirety. I posted a longer comment in another thread but the long and short of it is that accounts need to be portable if it’s going to work for a git hosting solution.
The comment: https://lemmy.zip/comment/26430897