fix(harness): resolve memorySpec by deployed ARN for arn-only memory refs#1407
Merged
Conversation
…refs When a harness references memory by ARN only (no name field), the previous lookup returned undefined, silently omitting retrievalConfig and excluding the memory from the configHash. resolveMemorySpec now walks deployedResources.memories to match by ARN and find the corresponding projectSpec memory, so name-less refs that point at a CLI-managed memory get the same treatment as name-based refs. HarnessMemoryRef is exported from the schema barrel so it can be used as the explicit parameter type on resolveMemorySpec. Adds unit tests for both the ARN-match path and the intentional undefined fallback for genuinely external memories.
Contributor
|
Claude Security Review: no high-confidence findings. (run) |
Contributor
Package TarballHow to installgh release download pr-1407-tarball --repo aws/agentcore-cli --pattern "*.tgz" --dir /tmp/pr-tarball
npm install -g /tmp/pr-tarball/aws-agentcore-0.15.0.tgz |
Contributor
Coverage Report
|
…rdown test The harness deletion can end in DELETE_FAILED due to backend issues unrelated to the CLI teardown logic. The e2e test should verify the deletion was attempted, not that the backend successfully completed it.
Contributor
|
Claude Security Review: no high-confidence findings. (run) |
The IAM permission fix (adding DeleteAgentRuntimeEndpoint) addresses the root cause. The e2e test should still fail on DELETE_FAILED to catch real issues.
Contributor
|
Claude Security Review: no high-confidence findings. (run) |
padmak30
approved these changes
May 28, 2026
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
namefield),resolveMemorySpecnow walksdeployedResources.memoriesto match by ARN and find the corresponding projectSpec memoryretrievalConfigand exclude the memory fromconfigHashHarnessMemoryReffrom the schema barrel for use as the explicit parameter typeCherry-picked from #1374 (third commit, missing from the feature-flag consolidation PR).
Related Issue
Closes #1097
Test plan
resolves memorySpec by deployed ARN when memory.name is absent)npm run typecheckpasses