StackGuardian / StackGuardian/tirith

Add resource address to the result

Open
#261 0 comments 0 reactions 1 assignee View on GitHub

@AkashS0510 is already working on this.

Since May 30, 2025.

enhancement
Dominant language
Python
Stars
165
Forks
42
Avg merge
1d 3h
Merged PRs (30d)
11

Description

Is your feature request related to a problem? Please describe.
Currently, when we do evaluations, Tirith is only printing the actual and expected value without any context (see image below)
Image

This is confusing for the user as they don't know which resource and tags is affected.

The image that I use there uses terraform_plan provider, but this has to be done for other providers as well, e.g. JSON provider, Kubernetes, etc.

Describe the solution you'd like
In JSON, we should have a new key to contain the resource address, e.g.

      {
         "id": "check2",
         "passed": false,
         "result": [
            {
               "passed": false,
               "message": "`null` is not equal to `{}`",
               "address": "aws_vpc.this[0].instance_tenancy.0.something",

The address key will have to contain the full adress of where the value was found.

In Text format, we should print the resource address, e.g

Check: check1
  PASSED
    1. PASSED: `"default"` is equal to `"default"` - (Address: `aws_vpc.this[0].instance_tenancy.0.something`)
    2. PASSED: `"default"` is equal to `"default"` - (Address: `aws_vpc.this[0].instance_tenancy.0.something`)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.