Verify and fix

From ubie-oss/terraform-provider-lightdash · View interactive version

Verify and fix is an AI agent skill from the GitHub repository ubie-oss/terraform-provider-lightdash. Run formatting, linters, unit tests, and build checks, then fix violations.

How to use this skill

Skill file

Verify and Fix

Purpose

Automate the process of ensuring code quality, functional correctness, and buildability within the Terraform Provider Lightdash project. This skill provides a comprehensive local verification loop using trunk, make, and pre-commit.

Safety & Restrictions

Workflow

1. Formatting

Start by ensuring consistent code formatting across the repository.

2. Linting

Execute the project's linting suite to identify violations.

3. Unit Testing

Execute the project's unit tests to ensure functional correctness.

4. Automated Fixing

If linter violations are detected, attempt to resolve them automatically.

5. Build Verification

Ensure the project compiles successfully and passes security/deadcode checks.

6. Iterative Manual Fixes

If issues remain after automated attempts, proceed with manual intervention.

Termination Criteria

Examples

Scenario: Fixing a Bug Found by Unit Tests

  1. Format: trunk fmt --all (Success).
  2. Lint: make lint (Success).
  3. Unit Testing: make test (Fails in internal/lightdash/api/utils_test.go).
  4. Manual Fix:
  1. Verify: Re-run make test. (Success).
  2. Build: make build. (Success).
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.