feat(als): integrate apme as diagnostics provider#2772
Draft
ganeshrn wants to merge 1 commit intoansible:mainfrom
Draft
feat(als): integrate apme as diagnostics provider#2772ganeshrn wants to merge 1 commit intoansible:mainfrom
ganeshrn wants to merge 1 commit intoansible:mainfrom
Conversation
Add apme (Ansible Policy & Modernization Engine) as a third diagnostics tool in the Ansible Language Server alongside ansible-lint and ansible-playbook --syntax-check. New capabilities: - AnsibleApme service: per-file and workspace-level validation via `apme check --json`, with three-tier violation classification (auto-fixable, ai-candidate, manual-review) - CodeActionProvider: "Fix all apme violations" quick fix for Tier 1 - Auto-fix on save: opt-in setting to auto-remediate deterministic violations - Workspace scan on startup: async background scan for project-wide violations - "Migrate with apme" command: command palette + explorer context menu for bulk remediation - Status bar indicator: violation count with click-to-problems - Diagnostic dedup: configurable precedence when both apme and ansible-lint report on the same line - Clickable rule IDs linking to apme documentation - Tier labels in diagnostic messages ([auto-fixable], [ai-candidate]) - Per-file remediation lock to prevent concurrent writes Settings: ansible.validation.apme.enabled, .path, .arguments, .autoFixOnSave, ansible.validation.diagnosticPrecedence Includes 15 unit tests for the JSON parser covering severity mapping, tier classification, file path handling, and edge cases. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Contributor
|
Label error. Requires at least 1 of: breaking, chore, feat, fix. Found: . Follow https://www.conventionalcommits.org to get auto-labeling to work correctly. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Changes
New files:
packages/ansible-language-server/src/services/ansibleApme.ts— AnsibleApme service (validation, workspace scan, remediation with per-file lock)packages/ansible-language-server/src/providers/codeActionProvider.ts— Quick fix code actions for Tier 1 violationspackages/ansible-language-server/test/services/ansibleApme.test.ts— 15 unit tests for JSON parserModified files:
package.json— apme settings, "Migrate with apme" command, explorer context menusrc/extension.ts— Migrate command handler, status bar indicatorpackages/ansible-language-server/src/ansibleLanguageService.ts— Code action handler, remediate request handlers, workspace scan on startuppackages/ansible-language-server/src/interfaces/extensionSettings.ts— apme settings typespackages/ansible-language-server/src/providers/validationProvider.ts— apme validation step + diagnostic deduppackages/ansible-language-server/src/services/settingsManager.ts— apme setting defaultspackages/ansible-language-server/src/services/workspaceManager.ts— ansibleApme lazy getterNew settings
ansible.validation.apme.enabledfalseansible.validation.apme.path"apme"ansible.validation.apme.arguments""ansible.validation.apme.autoFixOnSavefalseansible.validation.diagnosticPrecedence"both"both,apme, orlintTest plan
🤖 Generated with Claude Code