Skip to content

Conversation

fujiwara
Copy link
Collaborator

@fujiwara fujiwara commented Jul 20, 2025

Description

Two improvements to the verify command:

  1. Refactor verifyServiceDefinition - Extract verification logic into separate methods for better code organization
  2. Handle permission errors as warnings - Change permission errors from failures to warnings (yellow [WARN]) so verify can continue in restricted IAM environments

Example

When lacking Lambda permissions:

HookTargetArn[arn:aws:lambda:...]
--> [WARN] operation error Lambda: GetFunction, https response error StatusCode: 403, AccessDeniedException: User is not authorized to perform: lambda:GetFunction

Previously this would fail the entire verify command. Now it shows a warning and continues.

fujiwara and others added 2 commits July 20, 2025 17:17
- Extract verifyLoadBalancer method with AdvancedConfiguration support
- Extract verifyVpcLatticeConfiguration method
- Add verifyDeploymentConfiguration method with LifecycleHooks validation
- Add Lambda client for lifecycle hook target verification
- Improve code organization and readability

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
- Add ErrPermissionDenied type and WARN result status
- Implement isPermissionError to detect AWS permission errors
- Add wrapPermissionError helper for cleaner error handling
- Update verify functions to wrap permission errors appropriately
- Support both direct APIError and OperationError-wrapped errors
- Add comprehensive tests for permission error handling

This allows verify to continue when encountering permission errors
instead of failing completely, making it more usable in environments
with restricted permissions.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
@fujiwara fujiwara merged commit d5ce312 into v2 Jul 20, 2025
4 checks passed
@github-actions github-actions bot mentioned this pull request Jul 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant