Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

compile-custom fails on Windows 10 #83

Closed
kasingal opened this issue Oct 29, 2019 · 7 comments
Closed

compile-custom fails on Windows 10 #83

kasingal opened this issue Oct 29, 2019 · 7 comments

Comments

@kasingal
Copy link

kasingal commented Oct 29, 2019

It works on Ubuntu, MacOS but fails on Windows 10.
Using below execution configutration (with kroto-plus.version = 0.5.0)

<execution>
    <id>grpc-coroutines</id>
    <goals>
        <goal>compile-custom</goal>
    </goals>
    <configuration>
        <pluginId>kroto-plus</pluginId>
        <pluginArtifact>com.github.marcoferrer.krotoplus:protoc-gen-kroto-plus:${kroto-plus.version}:jar:jvm8</pluginArtifact>
        <pluginParameter>ConfigPath=./krotoPlusConfig.asciipb</pluginParameter>
    </configuration>
</execution>

Windows Info:

[INFO] ------------------------------------------------------------------------
[INFO] Detecting the operating system and CPU architecture
[INFO] ------------------------------------------------------------------------
[INFO] os.detected.name: windows
[INFO] os.detected.arch: x86_64
[INFO] os.detected.version: 10.0
[INFO] os.detected.version.major: 10
[INFO] os.detected.version.minor: 0
[INFO] os.detected.classifier: windows-x86_64

Failed Error Logs:

[INFO] --- protobuf-maven-plugin:0.6.1:compile-custom (grpc-coroutines) @ blueprint-proto ---
[INFO] Compiling 4 proto file(s) to C:\git\modules\target\generated-sources\protobuf\kroto-plus
[ERROR] PROTOC FAILED: --kroto-plus_out: protoc-gen-kroto-plus: This version of %1 is not compatible with the version of Windows you're running. Check your computer's system information and then contact the software publisher.

[ERROR] C:\git\modules\components\proto-definition\proto\CommandExecutor.proto [0:0]: --kroto-plus_out: protoc-gen-kroto-plus: This version of %1 is not compatible with the version of Windows you're running. Check your computer's system information and then contact the software publisher.

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
@marcoferrer
Copy link
Owner

marcoferrer commented Nov 15, 2019

Sorry about the delayed response. Im sorry but yes there are currently issues when using the plugin within windows environments. It is discussed extensively in #6

The quickest short term workaround is outlined in this comment #6 (comment)

There is a long term stable solution currently queued up for the next release is this PR #87

@mattdkerr
Copy link

Thanks @marcoferrer-- I left a single comment on the PR. Otherwise it looks good to me.

@marcoferrer
Copy link
Owner

marcoferrer commented Nov 19, 2019

@mattdkerr No worries. Thanks again for reporting. The PRs been merged and I published a snapshot of 0.6.0

Please let me know if you run into anymore issues. I’m really happy to get this resolved. The issues with windows compatibility have been bugging me for a while.

@mattdkerr
Copy link

mattdkerr commented Nov 19, 2019

I pulled in the 0.6.0-SNAPSHOT version and changed the line to look like:

artifact = "com.github.marcoferrer.krotoplus:protoc-gen-kroto-plus:$krotoPlusVersion"

and then I get successful generateProto and compileJava sequences. Thanks!

Will this then be released?

@marcoferrer
Copy link
Owner

Awesome thanks for the confirmation! The goal is to release later this week.

@jebbench
Copy link

Using 0.6.0-SNAPSHOT and removing :jvm8@jar from the artifact in my protobuf config got this working on Windows for me.

My full protobuf config is:

protobuf {
    protoc {
        artifact = "com.google.protobuf:protoc:$protobuf_version"
    }

    //noinspection GroovyAssignabilityCheck
    plugins {
        grpc { artifact = "io.grpc:protoc-gen-grpc-java:$grpc_version" }
        coroutines {
            artifact = "com.github.marcoferrer.krotoplus:protoc-gen-grpc-coroutines:$krotoplus_version"
        }
    }

    generateProtoTasks {
        all().each{ task ->
            task.plugins {
                grpc {}
                coroutines {}
            }
        }
    }
}

@marcoferrer
Copy link
Owner

With 0.6.0 released, there is now an executable windows artifact available.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants