Skip to content

kt_jvm_binary does not support non-java runtime_deps #1243

Open
@TwoClocks

Description

@TwoClocks

If you add a non-java runtime dependency to kt_jvm_binary, it fails with the below error.

In this case, I'm adding a C++ binary build in the same project.

Workaround:

replace kt_jvm_binary with java_binary and it works without any other changes.

line 656, column 25, in kt_jvm_produce_jar_actions
		java_info = JavaInfo(
	File "/virtual_builtins_bzl/common/java/java_info.bzl", line 752, column 35, in JavaInfo
	File "/virtual_builtins_bzl/common/java/java_info.bzl", line 690, column 52, in _javainfo_init
	File "/virtual_builtins_bzl/common/java/java_info.bzl", line 526, column 28, in _javainfo_init_base
	File "/virtual_builtins_bzl/common/java/java_info.bzl", line 482, column 51, in _validate_provider_list
Error in check_provider_instances: at index 1 of runtime_deps, got element of type NoneType, want JavaInfo

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions