bazelbuild / bazelbuild/rules_rust

Bug: `gen_rust_project` fails to parse `aquery` output when no Rust targets defined

Open
#2,176 0 comments 1 reaction 0 assignees View on GitHub
bug needs-triage rust-analyzer
Dominant language
Starlark
Stars
843
Forks
651
Avg merge
2d 18h
Merged PRs (30d)
15

Description

The `gen_rust_project` tool fails with a terse
```
Error: missing field `artifacts` at line 2 column 1
```
when run with a correct `rules_rust` WORKSPACE but no actual Rust targets have been defined.

This is because the returned JSON from `bazel aquery` is an empty dict in this case.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.