Fwd: Scala Breeze Dependencies not resolving when adding flink-ml on build.sbt

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Fwd: Scala Breeze Dependencies not resolving when adding flink-ml on build.sbt

Frederick Ayala
Hi,

I am getting an error when adding flink-ml to the libraryDependencies on my build.sbt file:

[error] (*:update) sbt.ResolveException: unresolved dependency: org.scalanlp#breeze_${scala.binary.version};0.11.2: not found

My libraryDependencies is:

libraryDependencies ++= Seq("org.apache.flink" % "flink-scala" % "0.9.1", "org.apache.flink" % "flink-streaming-scala" % "0.9.1", "org.apache.flink" % "flink-clients" % "0.9.1",
"org.apache.flink" % "flink-ml" % "0.9.1")

I am using scalaVersion := "2.10.6"

If I remove flink-ml all the other dependencies are resolved.

Could you help me to figure out a solution for this?

Thanks!

Frederick Ayala
Reply | Threaded
Open this post in threaded view
|

Re: Scala Breeze Dependencies not resolving when adding flink-ml on build.sbt

DEVAN M.S.
Can you add libraryDependencies += "org.scalanlp" % "breeze_2.10" % "0.11.2" also ?



Devan M.S. | Technical Lead | Cyber Security | AMRITA VISHWA VIDYAPEETHAM | Amritapuri | Cell +919946535290 | 
View DEVAN M S's profile on LinkedIn


On Wed, Oct 28, 2015 at 3:04 PM, Frederick Ayala <[hidden email]> wrote:
Hi,

I am getting an error when adding flink-ml to the libraryDependencies on my build.sbt file:

[error] (*:update) sbt.ResolveException: unresolved dependency: org.scalanlp#breeze_${scala.binary.version};0.11.2: not found

My libraryDependencies is:

libraryDependencies ++= Seq("org.apache.flink" % "flink-scala" % "0.9.1", "org.apache.flink" % "flink-streaming-scala" % "0.9.1", "org.apache.flink" % "flink-clients" % "0.9.1",
"org.apache.flink" % "flink-ml" % "0.9.1")

I am using scalaVersion := "2.10.6"

If I remove flink-ml all the other dependencies are resolved.

Could you help me to figure out a solution for this?

Thanks!

Frederick Ayala

Reply | Threaded
Open this post in threaded view
|

Re: Scala Breeze Dependencies not resolving when adding flink-ml on build.sbt

Frederick Ayala
I tried adding libraryDependencies += "org.scalanlp" % "breeze_2.10" % "0.11.2"  but the problem persist.

I also tried as explained in the Breeze documentation:

libraryDependencies  ++= Seq(
  "org.scalanlp" %% "breeze" % "0.11.2",
  "org.scalanlp" %% "breeze-natives" % "0.11.2",
  "org.scalanlp" %% "breeze-viz" % "0.11.2"
)

resolvers ++= Seq("Sonatype Releases" at "https://oss.sonatype.org/content/repositories/releases/")

But it doesn't work.

The message is still "unresolved dependency: org.scalanlp#breeze_${scala.binary.version};0.11.2: not found"

Could the problem be on flink-ml/pom.xml?

<dependency>
<groupId>org.scalanlp</groupId>
<artifactId>breeze_${scala.binary.version}</artifactId>
<version>0.11.2</version>
</dependency>

The property scala.binary.version is not being replaced by the value 2.10

Thanks,

Frederick Ayala

On Wed, Oct 28, 2015 at 10:59 AM, DEVAN M.S. <[hidden email]> wrote:
Can you add libraryDependencies += "org.scalanlp" % "breeze_2.10" % "0.11.2" also ?



Devan M.S. | Technical Lead | Cyber Security | AMRITA VISHWA VIDYAPEETHAM | Amritapuri | Cell <a href="tel:%2B919946535290" value="+919946535290" target="_blank">+919946535290 | 
View DEVAN M S's profile on LinkedIn


On Wed, Oct 28, 2015 at 3:04 PM, Frederick Ayala <[hidden email]> wrote:
Hi,

I am getting an error when adding flink-ml to the libraryDependencies on my build.sbt file:

[error] (*:update) sbt.ResolveException: unresolved dependency: org.scalanlp#breeze_${scala.binary.version};0.11.2: not found

My libraryDependencies is:

libraryDependencies ++= Seq("org.apache.flink" % "flink-scala" % "0.9.1", "org.apache.flink" % "flink-streaming-scala" % "0.9.1", "org.apache.flink" % "flink-clients" % "0.9.1",
"org.apache.flink" % "flink-ml" % "0.9.1")

I am using scalaVersion := "2.10.6"

If I remove flink-ml all the other dependencies are resolved.

Could you help me to figure out a solution for this?

Thanks!

Frederick Ayala




--
Frederick Ayala
Reply | Threaded
Open this post in threaded view
|

Re: Scala Breeze Dependencies not resolving when adding flink-ml on build.sbt

Anwar Rizal
Yeah....

I had similar problems with kafka in spark streaming. I worked around the problem by excluding kafka from connector and then adding the library back.

Maybe you can try something like:

libraryDependencies ++= Seq("org.apache.flink" % "flink-scala" % "0.9.1", "org.apache.flink" % "flink-clients" % "0.9.1" ,"org.apache.flink" % "flink-ml" % "0.9.1"  exclude("org.scalanlp", "breeze_${scala.binary.version}"))

libraryDependencies += "org.scalanlp" % "breeze_2.10" % "0.11.2"

Anwar.




On Wed, Oct 28, 2015 at 11:29 AM, Frederick Ayala <[hidden email]> wrote:
I tried adding libraryDependencies += "org.scalanlp" % "breeze_2.10" % "0.11.2"  but the problem persist.

I also tried as explained in the Breeze documentation:

libraryDependencies  ++= Seq(
  "org.scalanlp" %% "breeze" % "0.11.2",
  "org.scalanlp" %% "breeze-natives" % "0.11.2",
  "org.scalanlp" %% "breeze-viz" % "0.11.2"
)

resolvers ++= Seq("Sonatype Releases" at "https://oss.sonatype.org/content/repositories/releases/")

But it doesn't work.

The message is still "unresolved dependency: org.scalanlp#breeze_${scala.binary.version};0.11.2: not found"

Could the problem be on flink-ml/pom.xml?

<dependency>
<groupId>org.scalanlp</groupId>
<artifactId>breeze_${scala.binary.version}</artifactId>
<version>0.11.2</version>
</dependency>

The property scala.binary.version is not being replaced by the value 2.10

Thanks,

Frederick Ayala

On Wed, Oct 28, 2015 at 10:59 AM, DEVAN M.S. <[hidden email]> wrote:
Can you add libraryDependencies += "org.scalanlp" % "breeze_2.10" % "0.11.2" also ?



Devan M.S. | Technical Lead | Cyber Security | AMRITA VISHWA VIDYAPEETHAM | Amritapuri | Cell <a href="tel:%2B919946535290" value="+919946535290" target="_blank">+919946535290 | 
View DEVAN M S's profile on LinkedIn


On Wed, Oct 28, 2015 at 3:04 PM, Frederick Ayala <[hidden email]> wrote:
Hi,

I am getting an error when adding flink-ml to the libraryDependencies on my build.sbt file:

[error] (*:update) sbt.ResolveException: unresolved dependency: org.scalanlp#breeze_${scala.binary.version};0.11.2: not found

My libraryDependencies is:

libraryDependencies ++= Seq("org.apache.flink" % "flink-scala" % "0.9.1", "org.apache.flink" % "flink-streaming-scala" % "0.9.1", "org.apache.flink" % "flink-clients" % "0.9.1",
"org.apache.flink" % "flink-ml" % "0.9.1")

I am using scalaVersion := "2.10.6"

If I remove flink-ml all the other dependencies are resolved.

Could you help me to figure out a solution for this?

Thanks!

Frederick Ayala




--
Frederick Ayala

Reply | Threaded
Open this post in threaded view
|

Re: Scala Breeze Dependencies not resolving when adding flink-ml on build.sbt

Frederick Ayala
Thank you Anwar! That did the trick :)

On Wed, Oct 28, 2015 at 1:30 PM, Anwar Rizal <[hidden email]> wrote:
Yeah....

I had similar problems with kafka in spark streaming. I worked around the problem by excluding kafka from connector and then adding the library back.

Maybe you can try something like:

libraryDependencies ++= Seq("org.apache.flink" % "flink-scala" % "0.9.1", "org.apache.flink" % "flink-clients" % "0.9.1" ,"org.apache.flink" % "flink-ml" % "0.9.1"  exclude("org.scalanlp", "breeze_${scala.binary.version}"))

libraryDependencies += "org.scalanlp" % "breeze_2.10" % "0.11.2"

Anwar.




On Wed, Oct 28, 2015 at 11:29 AM, Frederick Ayala <[hidden email]> wrote:
I tried adding libraryDependencies += "org.scalanlp" % "breeze_2.10" % "0.11.2"  but the problem persist.

I also tried as explained in the Breeze documentation:

libraryDependencies  ++= Seq(
  "org.scalanlp" %% "breeze" % "0.11.2",
  "org.scalanlp" %% "breeze-natives" % "0.11.2",
  "org.scalanlp" %% "breeze-viz" % "0.11.2"
)

resolvers ++= Seq("Sonatype Releases" at "https://oss.sonatype.org/content/repositories/releases/")

But it doesn't work.

The message is still "unresolved dependency: org.scalanlp#breeze_${scala.binary.version};0.11.2: not found"

Could the problem be on flink-ml/pom.xml?

<dependency>
<groupId>org.scalanlp</groupId>
<artifactId>breeze_${scala.binary.version}</artifactId>
<version>0.11.2</version>
</dependency>

The property scala.binary.version is not being replaced by the value 2.10

Thanks,

Frederick Ayala

On Wed, Oct 28, 2015 at 10:59 AM, DEVAN M.S. <[hidden email]> wrote:
Can you add libraryDependencies += "org.scalanlp" % "breeze_2.10" % "0.11.2" also ?



Devan M.S. | Technical Lead | Cyber Security | AMRITA VISHWA VIDYAPEETHAM | Amritapuri | Cell <a href="tel:%2B919946535290" value="+919946535290" target="_blank">+919946535290 | 
View DEVAN M S's profile on LinkedIn


On Wed, Oct 28, 2015 at 3:04 PM, Frederick Ayala <[hidden email]> wrote:
Hi,

I am getting an error when adding flink-ml to the libraryDependencies on my build.sbt file:

[error] (*:update) sbt.ResolveException: unresolved dependency: org.scalanlp#breeze_${scala.binary.version};0.11.2: not found

My libraryDependencies is:

libraryDependencies ++= Seq("org.apache.flink" % "flink-scala" % "0.9.1", "org.apache.flink" % "flink-streaming-scala" % "0.9.1", "org.apache.flink" % "flink-clients" % "0.9.1",
"org.apache.flink" % "flink-ml" % "0.9.1")

I am using scalaVersion := "2.10.6"

If I remove flink-ml all the other dependencies are resolved.

Could you help me to figure out a solution for this?

Thanks!

Frederick Ayala




--
Frederick Ayala




--
Frederick Ayala
Reply | Threaded
Open this post in threaded view
|

Re: Scala Breeze Dependencies not resolving when adding flink-ml on build.sbt

Theodore Vasiloudis
In reply to this post by Frederick Ayala
The reason is (quoting Till, replace gradle with sbt here):

the flink-ml pom contains as a dependency an artifact with artifactId breeze_${scala.binary.version}. The variable scala.binary.version is defined in the parent pom and not substituted when flink-ml is installed. Therefore gradle tries to find a dependency with the name breeze_${scala.binary.version}

Anwar's solution should work, I just tested it on a basic Flink build, but I haven't tried running anything yet.
The resolution error does go away though. So your sbt should include something like:

libraryDependencies ++= Seq(
  "org.apache.flink" % "flink-scala" % flinkVersion,
  "org.apache.flink" % "flink-clients" % flinkVersion,
  ("org.apache.flink" % "flink-ml" % flinkVersion)
    .exclude("org.scalanlp", "breeze_${scala.binary.version}"),
  "org.scalanlp" %% "breeze" % "0.11.2")
 



On Wed, Oct 28, 2015 at 10:34 AM, Frederick Ayala <[hidden email]> wrote:
Hi,

I am getting an error when adding flink-ml to the libraryDependencies on my build.sbt file:

[error] (*:update) sbt.ResolveException: unresolved dependency: org.scalanlp#breeze_${scala.binary.version};0.11.2: not found

My libraryDependencies is:

libraryDependencies ++= Seq("org.apache.flink" % "flink-scala" % "0.9.1", "org.apache.flink" % "flink-streaming-scala" % "0.9.1", "org.apache.flink" % "flink-clients" % "0.9.1",
"org.apache.flink" % "flink-ml" % "0.9.1")

I am using scalaVersion := "2.10.6"

If I remove flink-ml all the other dependencies are resolved.

Could you help me to figure out a solution for this?

Thanks!

Frederick Ayala

Reply | Threaded
Open this post in threaded view
|

Re: Scala Breeze Dependencies not resolving when adding flink-ml on build.sbt

Frederick Ayala
Thanks Theodore. I can confirm that Anwar solution worked. My build.sbt looks like:

libraryDependencies  ++= Seq(
  "org.scalanlp" %% "breeze" % "0.11.2",
  "org.scalanlp" %% "breeze-natives" % "0.11.2",
  "org.scalanlp" %% "breeze-viz" % "0.11.2"
)

libraryDependencies ++= Seq("org.apache.flink" % "flink-scala" % "0.9.1", 
"org.apache.flink" % "flink-streaming-scala" % "0.9.1",
"org.apache.flink" % "flink-clients" % "0.9.1",
              "org.apache.flink" % "flink-ml" % "0.9.1" exclude("org.scalanlp", "breeze_${scala.binary.version}")
)

resolvers ++= Seq("Sonatype Releases" at "https://oss.sonatype.org/content/repositories/releases/")



On Wed, Oct 28, 2015 at 1:41 PM, Theodore Vasiloudis <[hidden email]> wrote:
The reason is (quoting Till, replace gradle with sbt here):

the flink-ml pom contains as a dependency an artifact with artifactId breeze_${scala.binary.version}. The variable scala.binary.version is defined in the parent pom and not substituted when flink-ml is installed. Therefore gradle tries to find a dependency with the name breeze_${scala.binary.version}

Anwar's solution should work, I just tested it on a basic Flink build, but I haven't tried running anything yet.
The resolution error does go away though. So your sbt should include something like:

libraryDependencies ++= Seq(
  "org.apache.flink" % "flink-scala" % flinkVersion,
  "org.apache.flink" % "flink-clients" % flinkVersion,
  ("org.apache.flink" % "flink-ml" % flinkVersion)
    .exclude("org.scalanlp", "breeze_${scala.binary.version}"),
  "org.scalanlp" %% "breeze" % "0.11.2")
 



On Wed, Oct 28, 2015 at 10:34 AM, Frederick Ayala <[hidden email]> wrote:
Hi,

I am getting an error when adding flink-ml to the libraryDependencies on my build.sbt file:

[error] (*:update) sbt.ResolveException: unresolved dependency: org.scalanlp#breeze_${scala.binary.version};0.11.2: not found

My libraryDependencies is:

libraryDependencies ++= Seq("org.apache.flink" % "flink-scala" % "0.9.1", "org.apache.flink" % "flink-streaming-scala" % "0.9.1", "org.apache.flink" % "flink-clients" % "0.9.1",
"org.apache.flink" % "flink-ml" % "0.9.1")

I am using scalaVersion := "2.10.6"

If I remove flink-ml all the other dependencies are resolved.

Could you help me to figure out a solution for this?

Thanks!

Frederick Ayala




--
Frederick Ayala