chore(audit): close remaining stub gaps + ECS tag coverage#767
Merged
vieiralucas merged 2 commits intomainfrom Apr 25, 2026
Merged
chore(audit): close remaining stub gaps + ECS tag coverage#767vieiralucas merged 2 commits intomainfrom
vieiralucas merged 2 commits intomainfrom
Conversation
Closes the audit pass after the 9 prior implementation batches. Three real fixes plus a doc-honesty pass: - ECS: TagResource/UntagResource/ListTagsForResource now cover service, task, task-set, container-instance, and capacity-provider on top of the existing cluster + task-definition. The state already carried tag vectors on each of these structs; the dispatch was rejecting them with "not yet supported". - SSM SendCommand/ListCommands no longer return literal "Details placeholder" for StatusDetails; mirrors the command Status as AWS does. - DynamoDB and SSM "Stubs" comment headers retitled to "Synthetic defaults" — the listed ops are intentional canned defaults (DescribeEndpoints, DescribeLimits, GetConnectionStatus, GetCalendarState, DescribePatchGroupState, DescribeAvailablePatches) plus real-state ops (DescribePatchProperties, GetDefaultPatchBaseline, GetServiceSetting, ResetServiceSetting, UpdateServiceSetting). "Stubs" was misleading. - New E2E `tag_untag_service_and_capacity_provider` exercises the expanded ECS tagging surface.
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
There was a problem hiding this comment.
2 issues found across 6 files
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="crates/fakecloud-ecs/src/service.rs">
<violation number="1" location="crates/fakecloud-ecs/src/service.rs:1220">
P2: Service tag operations use `tail` directly as the state key, which breaks for short service ARNs (`service/<name>`) because stored keys are `cluster/service`.</violation>
<violation number="2" location="crates/fakecloud-ecs/src/service.rs:1242">
P2: Container-instance tag operations lookup by raw ARN tail, which fails for short ARNs because state keys are stored as `cluster/id`.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
Cubic flagged the new tag handlers using the raw ARN tail as the storage-map key. Long-form ARNs already match (`cluster/name`), but short-form ARNs (account-setting `serviceLongArnFormat=disabled` or `containerInstanceLongArnFormat=disabled`) carry only the bare name, so lookups returned ResourceNotFound. - Add `resolve_service_key` and `resolve_container_instance_key` helpers that recognise both forms: long tail used directly when present, short tail resolved by scanning for a stored key ending with `/<tail>`. - Wire all three tag operations (Tag/Untag/ListTags) through the resolver for service + container-instance. - Unit tests cover the two-form lookup and unknown-name fallthrough.
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
TagResource/UntagResource/ListTagsForResourcenow cover service, task, task-set, container-instance, and capacity-provider on top of cluster + task-definition.StatusDetailsmirroring the command status (was literal"Details placeholder").Test plan
cargo test -p fakecloud-ssm --lib(199 pass)cargo test -p fakecloud-ecs --lib(30 pass)tag_untag_service_and_capacity_providerpassestag_untag_cluster_and_task_definitionstill passescargo clippy --workspace --all-targets -- -D warningscleancargo fmt --checkcleanSummary by cubic
Expands ECS tagging to services, tasks, task sets, container instances, and capacity providers, and fixes short-ARN lookups for services and container instances. Also aligns SSM command StatusDetails with Status and clarifies DynamoDB/SSM comments as “Synthetic defaults.”
New Features
TagResource/UntagResource/ListTagsForResourcenow support service, task, task-set, container-instance, and capacity-provider.Bug Fixes
SendCommandandListCommandsnow setStatusDetailsto matchStatus(was a placeholder).Written for commit 83963f9. Summary will update on new commits.