bug: Support non-string (bool/int) attribute values in Tango
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 65/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- go
- Domain
- backend, distributed-systems
Research direction
Start by examining mapper/mapper.go lines 69-77 to see the current string-only filter. Review proto/tango.proto to understand the Metadata structure and plan the additive changes. Then, look at core/itg/graph/graph.go for interning logic and internal/targetdiff/compare.go line 142 for attribute comparison. A good first step is to run existing tests to ensure they pass before modifying the type handling.
Written by the indexing model from the issue text.
Description
Problem
Tango only propagates string-valued Bazel attributes. mapper/mapper.go:69-77 filters ingestion to Attribute_STRING only — bool/int/other types are dropped before reaching the graph, and the proto (proto/tango.proto) has no field to carry them anyway.
Effect: internal/targetdiff/compare.go:142 can't see non-string attribute changes, so a target whose only real change is e.g. a boolean flip still gets flagged as changed (via hash) but is misclassified as INDIRECT instead of DIRECT.
Proposed Solution
- Add typed value mapping(s) to Metadata in proto/tango.proto (additive, backward compatible).
- Remove the STRING-only filter in mapper/mapper.go; route by attr.GetType().
- Update interning in core/itg/graph/graph.go to handle typed values, not just GetStringValue().
- Extend attributesChanged in internal/targetdiff/compare.go to compare typed values.
- Dominant language
- Go
- Stars
- 23
- Forks
- 12
- Avg merge
- 1d 10h
- Merged PRs (30d)
- 18
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from uber/tango
-
Support Bazel repository contents cachePossibly taken @xytan0056 claimed this 18 days ago. Openbug
Difficulty 3/5 1-2 days Newbie friendliness 68/100
uber/tango#338 · 3 comments · 1 reaction ·
Maintainers usually reply within 1 day
-
race in core/bazelMay be free again @sywhang claimed this 136 days ago, and no pull request is open. Open
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
Maintainers usually reply within 1 day
-
Difficulty 3/5 1-2 days Newbie friendliness 25/100
Maintainers usually reply within 1 day
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 72/100
kubescape/node-agent#1099 ·
Maintainers usually reply within 1 day
-
import-export
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
genealogix/glx#1498 ·
Maintainers usually reply within 2 days
-
Docs: 2 broken linksOpenBug pulumi/pulumi-terraform-bridge R2 S2
Difficulty 1/5 Under an hour Newbie friendliness 72/100
pulumi/pulumi-terraform-bridge#3713 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
ossf/pvtr-github-repo-scanner#539 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
goreleaser/goreleaser#7316 ·
Maintainers usually reply within 1 day