【问题标题】:"Cannot resolve symbol error" while trying to import Circe project to intellij (scala)尝试将 Circe 项目导入 intellij (scala) 时出现“无法解决符号错误”
【发布时间】:2022-03-25 18:39:40
【问题描述】:

将Circe项目导入intellij后,intellij无法识别“TupleEncoders”,但是sbt compile没问题。我看到 TupleEncoder 是一个生成的源。有什么想法吗?

【问题讨论】:

  • 您使用什么 IDEA 和 Scala/SBT 版本?您是否在“设置 | 构建... | 构建工具 | SBT”中启用了“使用 SBT shell 进行构建和导入”选项?
  • 是的,我确实启用了。
  • 请检查生成的文件夹是否标记为“生成的源根目录”

标签: scala intellij-idea sbt circe


【解决方案1】:

也许没有太大帮助,但请查看How to force IntelliJ IDEA to reload dependencies from build.sbt after they changed? 中的答案,它确实对我有用。

你必须点击IDE右边缘的“sbt”,它会打开一个小窗口,点击刷新图标,一切都应该没问题。

【讨论】:

    猜你喜欢
    • 2023-01-05
    • 2016-01-27
    • 2018-07-06
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-12-24
    相关资源
    最近更新 更多