I use Git remote operations like pull, push, and fetch very often and usually in quick succession. However, after I started using two GitHub accounts on my computer, I noticed that these operations would often get stuck if done too close together. It is almost as if there is an operation limit of 1 or 2 per minute. If I call git push and then git pull immediately after, the git pull will hang and never finish. However, if I wait a minute, then the git pull command will work again.
I've tried many ways to configure working with two GitHub accounts on my computer. I use SSH so I have a proper ssh config file set up with two keys and separate hosts. This did not work. I'm currently using the .gitconfig method where I identify what ssh command to use per repo. This also does not work.
How can I diagnose the cause of this problem and how can I fix it?
My Setup:
- macOS Monterey
- Git version 2.37.1
- Standard firewall and antivirtus (nothing special)
Thanks!