Add terraform-azurerm-set-diff-analyzer skill#620
Conversation
There was a problem hiding this comment.
Pull request overview
Adds a new entry to the skills index for a Terraform/AzureRM “set diff” analyzer intended to help interpret Terraform plan JSON output and distinguish order-only diffs from real changes.
Changes:
- Added a
terraform-azurerm-set-diff-analyzerrow todocs/README.skills.md, including a link and a list of bundled assets.
docs/README.skills.md
Outdated
| | [refactor](../skills/refactor/SKILL.md) | Surgical code refactoring to improve maintainability without changing behavior. Covers extracting functions, renaming variables, breaking down god functions, improving type safety, eliminating code smells, and applying design patterns. Less drastic than repo-rebuilder; use for gradual improvements. | None | | ||
| | [scoutqa-test](../skills/scoutqa-test/SKILL.md) | This skill should be used when the user asks to "test this website", "run exploratory testing", "check for accessibility issues", "verify the login flow works", "find bugs on this page", or requests automated QA testing. Triggers on web application testing scenarios including smoke tests, accessibility audits, e-commerce flows, and user flow validation using ScoutQA CLI. IMPORTANT: Use this skill proactively after implementing web application features to verify they work correctly - don't wait for the user to ask for testing. | None | | ||
| | [snowflake-semanticview](../skills/snowflake-semanticview/SKILL.md) | Create, alter, and validate Snowflake semantic views using Snowflake CLI (snow). Use when asked to build or troubleshoot semantic views/semantic layer definitions with CREATE/ALTER SEMANTIC VIEW, to validate semantic-view DDL against Snowflake via CLI, or to guide Snowflake CLI installation and connection setup. | None | | ||
| | [terraform-azurerm-set-diff-analyzer](https://github.com/torumakabe/terraform-azurerm-set-diff-analyzer/blob/main/.github/skills/terraform-azurerm-set-diff-analyzer/SKILL.md) | Analyze Terraform plan JSON output for AzureRM Provider to distinguish between false-positive diffs (order-only changes in Set-type attributes) and actual resource changes. Use when reviewing terraform plan output for Azure resources like Application Gateway, Load Balancer, Firewall, Front Door, NSG, and other resources with Set-type attributes that cause spurious diffs due to internal ordering changes. | `references/azurerm_set_attributes.json`<br />`references/azurerm_set_attributes.md`<br />`scripts/analyze_plan.py` | |
There was a problem hiding this comment.
This table entry doesn’t appear to correspond to a skill included in this repo: there is no skills/terraform-azurerm-set-diff-analyzer/ folder, and unlike all other entries it links out to an external GitHub URL. Also, the “Bundled Assets” column lists files that aren’t present under a local skill folder, which conflicts with this doc’s own definition that skills are “self-contained folders” in skills/.
Suggested fix: add the skill folder and assets under skills/terraform-azurerm-set-diff-analyzer/ and update the link to ../skills/terraform-azurerm-set-diff-analyzer/SKILL.md (and keep bundled asset paths relative to that folder), or if external skills are intended to be listed here, update the README to explicitly support external skills and avoid listing local bundled-asset paths for them.
faecb20 to
269534f
Compare
Add a new skill that analyzes Terraform plan JSON output for AzureRM Provider to distinguish between false-positive diffs (order-only changes in Set-type attributes) and actual resource changes. This skill helps users identify 'noise' in terraform plan output caused by Azure API returning Set elements in different order, making plan reviews easier and reducing confusion in CI/CD pipelines. Bundled assets: - references/azurerm_set_attributes.json - references/azurerm_set_attributes.md - scripts/analyze_plan.py
269534f to
1b9ff37
Compare
aaronpowell
left a comment
There was a problem hiding this comment.
Wanting to confirm, the .gitignore included in this is to ensure that running the analyze_plan.py script won't accidentally add files to the repo that are artifacts of running the script.
Also, the skill makes the assumption that Python is installed on the machine, I'd recommend some troubleshooting advice in the skill on how to handle if it's unavailable or if the script is unsuccessful.
|
@aaronpowell Thank you for the review!
Yes, exactly. It prevents Python artifacts (pycache/, .pyc files, virtual environments, etc.) from being committed when developing or running the script locally.
Added Prerequisites and Troubleshooting sections to SKILL.md in a6f3cde. The script also returns meaningful exit codes (0-3) and writes errors to stderr, so coding agents can handle failures programmatically. |
Summary
Add a new skill that analyzes Terraform plan JSON output for AzureRM Provider to distinguish between false-positive diffs (order-only changes in Set-type attributes) and actual resource changes.
Problem
When working with Azure resources that use Set-type attributes (like Application Gateway, Load Balancer, NSG, etc.),
terraform planoften shows all elements as "changed" even when you only added or removed a single element. This is because Terraform's Set type compares by position rather than by key.These "false-positive diffs" don't actually affect the resources, but they make reviewing terraform plan output difficult and can cause confusion in CI/CD pipelines.
Solution
This skill identifies and categorizes changes in Set-type attributes:
Skill Repository
https://github.com/torumakabe/terraform-azurerm-set-diff-analyzer
Bundled Assets
references/azurerm_set_attributes.json- Set-type attribute definitions for AzureRM resourcesreferences/azurerm_set_attributes.md- Human-readable documentationscripts/analyze_plan.py- Python analyzer scriptChecklist