I ran into the same issue, and I’d like to respond to the question raised by Aakash Patel back in 2019.
In my opinion, the root cause might not be about checking the specific version of the missing JAR file, or importing, modifying, or deleting certain files in the project.
Instead, the issue could lie in the JDK or other references being incorrectly configured during the build process.
My project was created as a Maven Project, and after reviewing and correcting the JDK version used by Java, the problem was resolved — the related errors stopped appearing.
To sum up, I suggest looking into the root configuration of the build environment rather than fixing individual files. This approach might be more effective in the long run.