Steps to the Reproduce:
You need to set up the IronPython 2.7 environment*.
*Currently you cannot do it through the Visual Studio Installer (there isn't an IronPython Package option to install).
Hopefully, Microsoft will patch this in the future.
When switching from Python 3.8 to 3.9 I came across the same error (also with pylint). I simply edited the project.pyproj (xml) file from: <InterpreterId>Global|PythonCore|3.8</InterpreterId>
to: <InterpreterId>Global|PythonCore|3.9</InterpreterId>
.
Download the msi file for IronPython from Github. Then copy the path where it is downloaded and add it to the path in the system environment variable. Then restart visual studio. Select the project and set the python environment to IronPython.