Closed smarijic closed 4 years ago
This is still the issue as of version 0.8.4 of the plugin.
This looks similar to #545, do you have the 'scala' plugin enabled?
I think we have seen this problem in other places as well, though - but I can't find a reference right now.
I wonder if the improvements in #1042 might help here as well.
I have same issue (opened one that got closed and referred to this) and the 'scala' plugin is enabled as it is for a scala-project.
We're also seeing this problem in akka-grpc-quickstart-java.g8: #1034
The strange thing is we're not seeing it in the akka-grpc travis tests, and not on the akka-grpc-quickstart-scala.g8 tests (https://github.com/akka/akka-grpc-quickstart-scala.g8).
Do you also see the problem when you use the quickstart project? Can anyone spot the difference?
@raboof which repo should be taken into consideration for this bug ? I could take a look
@eshepelyuk that would be great!
It's hard to say where to start since it's still unclear what's triggering the problem - I can at least reproduce #1034 with sbt new akka/akka-grpc-quickstart-java.g8
and then ./gradlew build
, even when I update the plugin version to 1.0.0-17-3dcade13
@raboof is there any existing repo to start with ?
i don't have sbt and no sure what sbt new
is doing at all.
ah, sorry :).
The code is in https://github.com/akka/akka-grpc-quickstart-java.g8 . Unfortunately this is a 'template', so you'll need the g8 tool to apply it: http://www.foundweekends.org/giter8/usage.html .
(Also I just noticed the jar artifacts of 1.0.0-17-3dcade13 haven't been uploaded correctly, but the problem occurs even before that)
But this repo doesn't have build.gradle
, how one could run Gradle ?
@eshepelyuk you have two options:
sbt
and use sbt new akka/akka-grpc-quickstart-java.g8
, orsbt
from https://developer.lightbend.com/start/?group=akka&project=akka-grpc-quickstart-java:-)
this repo doesn't have build.gradle , how one could run Gradle ?
This repo is the template, it will process the files in https://github.com/akka/akka-grpc-quickstart-java.g8/tree/master/src/main/g8 to form a (local) repository that does have a build.gradle.
you have two options:
Actually if you don't have sbt you can also invoke g8 'directly' as documented at http://www.foundweekends.org/giter8/usage.html . But indeed getting the package at https://developer.lightbend.com/start/?group=akka&project=akka-grpc-quickstart-java is probably even more convenient
I get the same error with akka-grpc-quickstart-java.g8
, but not with akka-grpc-quickstart-scala
. My project is based on the akka-grpc-quickstart-scala
setup which does provoke the same error on ./gradlew build
@Chr1stian interesting, can you figure out what's the difference? Perhaps something with gradle version?
Is snapshot of gradle plugin published as well ?
Is snapshot of gradle plugin published as well ?
Yes: https://plugins.gradle.org/m2/com/lightbend/akka/grpc/akka-grpc-gradle-plugin/
Well, I am testing the latest version ( including my changes) and it seems I've introduced another plugin application bug.
@raboof @ignasi35 I will provide a PR for fixing this issues and a regression I've introduced in my previous PR. Fix seems working - need to refactor tests for a plugin.
Created #1054
Looks like this should now be fixed on master, tested with akka-grpc snapshot version 1.0.0-24-1ff30e97 (adding the snapshot repository to the gradle build as maven { url 'http://dl.bintray.com/akka/snapshots' })
@eshepelyuk do you want to do a final test before we close this issue (and perhaps release akka-grpc 1.0.1 to get this improvement out there)?
Already did some testing and auto tests are passing too. Seems like working now.
Great, thanks for this great work!
Hi again,
Thanks for the effort @eshepelyuk , might be something I am doing wrong, but DSL seems to still not be working for my project.
After adding id "com.lightbend.akka.grpc.gradle" version "1.0.0-25-716e655d"
to plugins I get the following error when building gradle:
A problem occurred configuring root project 'my-project-name'.
> Could not resolve all dependencies for configuration ':compileClasspathCopy'.
You likely have to add the snapshot repository to be able to fetch the libraries:
maven { url 'http://dl.bintray.com/akka/snapshots' }
repositories {
maven {
url 'http://dl.bintray.com/akka/snapshots'
}
jcenter()
}
Still same error :/
That's weird, the quickstart seems to work for me. Can you share the complete output?
This worked for me ( modified plugin-tester-scala
)
plugins {
id "com.lightbend.akka.grpc.gradle" version "1.0.0-29-572f9dc1"
}
akkaGrpc {
serverPowerApis = true // This isn't default
}
repositories {
mavenCentral()
maven {
url "https://dl.bintray.com/akka/snapshots"
}
}
def scalaBinaryVersion = "2.12"
dependencies {
implementation group: 'ch.megard', name: "akka-http-cors_${scalaBinaryVersion}", version: '0.4.2'
testImplementation "com.typesafe.akka:akka-stream-testkit_${scalaBinaryVersion}:2.5.31"
testImplementation "org.scalatest:scalatest_${scalaBinaryVersion}:3.1.2"
testImplementation "org.scalatestplus:junit-4-12_${scalaBinaryVersion}:3.1.2.0"
}
@raboof I got a proposal - plugin may analyze its version and automatically add akka snapshot repository to the project repositories for version resolution.
It will remove a need to boilerplate this piece of build file when trying to use snapshot versions.
maven {
url "https://dl.bintray.com/akka/snapshots"
}
Thanks guys! 🥇 I could not share the entire output as there are some privacy concerns for my company, sorry about that. If I had posted it you could probably have told me what the issue was at once :p I just had to specify the repository for some local/JFrog plugins/dependencies and all is fine. Thanks again! Looking forward to a new full release with the fix included 👍
@raboof I got a proposal - plugin may analyze its version and automatically add akka snapshot repository to the project repositories for version resolution.
It will remove a need to boilerplate this piece of build file when trying to use snapshot versions.
maven { url "https://dl.bintray.com/akka/snapshots" }
That sounds great to me!
Thanks guys! 1st_place_medal I could not share the entire output as there are some privacy concerns for my company
Makes sense!
I just had to specify the repository for some local/JFrog plugins/dependencies and all is fine. Thanks again! Looking forward to a new full release with the fix included +1
Thanks for validating! I'll be happy to cut a 1.0.1 version soon - @eshepelyuk is there anything more you'd like to get in there before I do?
Thanks for validating! I'll be happy to cut a 1.0.1 version soon - @eshepelyuk is there anything more you'd like to get in there before I do?
yes - I would like to cleanup that thing with publishToMavenLocal
in Travis CI pipeline.
And implement consistent approach for both java and scala projects.
Also docs update.
Hi,
I can't include akka-grpc using plugin DSL as it fails with following error:
I've tried multiple gradle versions also, same result. Legacy usage with classpath works.
Is there something that I've missed?