-
Notifications
You must be signed in to change notification settings - Fork 4.3k
fix(scheduler): scheduleName returns undefined when imported from ARN #36400
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The pull request linter fails with the following errors:
❌ Fixes must contain a change to an integration test file and the resulting snapshot.
If you believe this pull request should receive an exemption, please comment and provide a justification. A comment requesting an exemption should contain the text Exemption Request. Additionally, if clarification is needed, add Clarification Request to a comment.
✅ A exemption request has been requested. Please wait for a maintainer's review.
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
|
||||||||||||||
|
||||||||||||||
|
Exemption Request: This change only fixes ARN parsing logic in a static import method and does not interact with AWS APIs. Unit tests fully cover the parsing logic and error handling. |
Issue # (if applicable)
Closes #36361.
Reason for this change
When importing a schedule using
Schedule.fromScheduleArn(), thescheduleNameproperty returnsundefinedinstead of the actual schedule name.Description of changes
Fixed the ARN parsing logic in
Schedule.fromScheduleArn()to correctly extract the schedule name from the resource path. AWS Scheduler ARNs have the formatarn:aws:scheduler:region:account:schedule/GROUP/NAME, and the previous implementation only captured the group name.Describe any new or updated permissions being added
No new or updated permissions.
Description of how you validated changes
Added unit tests to verify correct parsing and error handling.
Checklist
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license