Pit stop times matter, and supercapacitors exist.
I'd love to watch that race, especially if the cars were sucker cars like the one in the article, and the drivers got to wear high-G fighter jet suits.
The best supercapacitors apparently have 20x the energy density of the best batteries. Apparently, self-discharge can be as low as 20% per day, which rounds to zero for racing. They only cost 10x more than lithium batteries, which again, for racing rounds to zero. Discharge current blows lithium-ion so far out of the water that I couldn't find a rule of thumb ratio.
https://supercaptech.com/battery-vs-supercapacitor/
edit: I had the energy density backwards; supercapacitors are at 10% the density of lithium ion. Still, the other advantages stand. I wonder how hard it would be to add an inductive charger to a straightaway...