StackGuardian / StackGuardian/tirith

Reject unknown parameter if provided by the user (usually caused by typos)

Open
#125 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

Users usually have a typo in their policy's provider_args for example. Like terraform_plan's referenced_by usually typo'ed by the user to references_by. The current behavior when such typos is happening is tirith will continue to run as usual. We need to add a mechanism to reject the unknown parameters so that the user knows that the parameter is not needed and thus can be removed (which also makes tirith policies that are written by the user cleaner and more readable)

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.

Research direction

Start at the policy provider_args handling for terraform_plan, using the referenced_by and references_by example to trace how parameters are accepted. The work is done when unknown parameters are rejected and the user is told which parameter is invalid, with coverage for the typo case.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, terraform
Domain
backend, devtools
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.