This problem happens intermittently for different libraries and different projects. When trying to import a library, the package will be recognized, but the class name can\'
Please try File-> Synchronize. Then close and reopen IntelliJ before you invalidate.
Once I restarted. I would have invalidated but the synchronize cleared everything after restarting.