Corrupted Arduino ?

Lots of changes happened between ESP package 2 and 3.
As others have said, try reverting back to the last version 2 (2.0.17).
Leo..