“Unknown artifact. Not resolved or indexed” error for scalatest

ε祈祈猫儿з 提交于 2019-11-27 13:27:39

If you just added the dependency, it might not have been downloaded yet. Refresh/reimport the project to do so.

If it has already been downloaded, press Alt+Enter in IntelliJ on the lines with the warning and select the "update project resolvers' indexes" quickfix, then select the "local cache" index and click "update".

You can verify that the update worked by checking the date in the "Updated" column:

I had the same problem. File -> Invalidate Caches/Restart... fixed the issue for me.
Just updating/refreshing project didn't work in my case.

In my situation, I tried:

  1. Alt + Enter then Refresh Project.
  2. Update Resolvers' Local cache.
  3. File -> Invalidate Caches/Restart.

None of the above worked. So for future reference, here is my solution for this issue:

  1. Ensure Maven Integration plugin is enabled, and instead of updating Resolvers's Local cache, update the public which is Never Updated.

This process may take some time to finish download if it's a newly installed IntelliJ IDEA.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!