object scalapb is not a member of package <root>

543 views
Skip to first unread message

Yang Liu

unread,
Apr 11, 2018, 10:22:10 PM4/11/18
to ScalaPB
Hi all,

I setup the project as the instructions of scalapb.github.io, and run `sbt compile` successfully. But when I build the project in IntelliJ IDEA, the IDE gives following errors as title

Part of the errors look like this:

Information:12/4/18, 9:41 AM - Compilation completed with 75,334 errors and 0 warnings in 59s 99ms
/Users/yang.liu/dev/insight-service/target/scala-2.12/src_managed/main/PBData/Base/BaseProto.scala
    Error:Error:line (8)object scalapb is not a member of package <root>
object BaseProto extends _root_.scalapb.GeneratedFileObject {
    Error:Error:line (9)object scalapb is not a member of package <root>
  lazy val dependencies: Seq[_root_.scalapb.GeneratedFileObject] = Seq(
    Error:Error:line (11)object scalapb is not a member of package <root>
  lazy val messagesCompanions: Seq[_root_.scalapb.GeneratedMessageCompanion[_]] = Seq(
    Error:Error:line (18)not found: value scalapb
      scalapb.Encoding.fromBase64(scala.collection.Seq(
    Error:Error:line (22)object scalapb is not a member of package <root>
  lazy val scalaDescriptor: _root_.scalapb.descriptors.FileDescriptor = {
    Error:Error:line (23)object google is not a member of package com
    val scalaProto = com.google.protobuf.descriptor.FileDescriptorProto.parseFrom(ProtoBytes)
    Error:Error:line (24)object scalapb is not a member of package <root>
    _root_.scalapb.descriptors.FileDescriptor.buildFrom(scalaProto, dependencies.map(_.scalaDescriptor))
    Error:Error:line (26)object google is not a member of package com
  lazy val javaDescriptor: com.google.protobuf.Descriptors.FileDescriptor = {
    Error:Error:line (27)object google is not a member of package com
    val javaProto = com.google.protobuf.DescriptorProtos.FileDescriptorProto.parseFrom(ProtoBytes)
    Error:Error:line (28)object google is not a member of package com
    com.google.protobuf.Descriptors.FileDescriptor.buildFrom(javaProto, Array(
    Error:Error:line (32)object google is not a member of package com
  def descriptor: com.google.protobuf.Descriptors.FileDescriptor = javaDescriptor
/Users/yang.liu/dev/insight-service/target/scala-2.12/src_managed/main/PBData/Base/String.scala
    Error:Error:line (65)not found: value scalapb
object String extends scalapb.GeneratedMessageCompanion[PBData.Base.String] {
    Error:Error:line (11)not found: value scalapb
    ) extends scalapb.GeneratedMessage with scalapb.Message[String] with scalapb.lenses.Updatable[String] {
    Error:Error:line (11)not found: value scalapb
    ) extends scalapb.GeneratedMessage with scalapb.Message[String] with scalapb.lenses.Updatable[String] {


Thanks

Nadav Samet

unread,
Apr 12, 2018, 12:40:03 AM4/12/18
to Yang Liu, ScalaPB
Try importing the project into IntelliJ again, or have it refresh the build.sbt file.

--
You received this message because you are subscribed to the Google Groups "ScalaPB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scalapb+u...@googlegroups.com.
To post to this group, send email to sca...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/scalapb/db7386e2-cd54-450e-8c50-99e3f794d585%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
-Nadav
Reply all
Reply to author
Forward
0 new messages