RStudio seems to struggle with 2-Factor Authentication

I have two factor authentication set up on my GitHub profile. When connect to my account from RStudio, a prompt window comes up to ask for my credentials.

It seems that the internal process used to supply log in credentials to RStudio doesn't handle two-factor authentication well. It just takes a username and password, and then inevitably fails because the GitHub servers want the 2FA but the IDE provides no dialog for this.

Has anybody else noticed this? I would like to confirm the issue before creating an issue on the GitHub repo for RStudio.