Just use Tectonic nowadays for compiling LaTeX source. It automatically handles these cases of compiling multiple times.

+1 for tectonic, it's miles better than the alternatives for every single case, in my experience. Development seems to have slowed down lately, which is a shame.