Skip to content

fix(cloud-security): reconcile conflicting logGroupName guidance in fix prompt#3054

Merged
tofikwest merged 1 commit into
mainfrom
tofik/metric-filter-loggroup-prompt
Jun 5, 2026
Merged

fix(cloud-security): reconcile conflicting logGroupName guidance in fix prompt#3054
tofikwest merged 1 commit into
mainfrom
tofik/metric-filter-loggroup-prompt

Conversation

@tofikwest
Copy link
Copy Markdown
Contributor

@tofikwest tofikwest commented Jun 5, 2026

Summary

Cubic follow-up to the metric-filter work (#3050). The fix-plan prompt gave the model two conflicting instructions for the CloudWatch logGroupName:

  • The new CLOUDWATCH METRIC FILTERS section: "logGroupName must be the REAL CloudTrail CloudWatch Logs group name from the read step — never a placeholder."
  • The older NO PLACEHOLDERS section: "CloudTrail log group: use "CloudTrail/DefaultLogGroup" (the system will resolve the real one from readSteps)."

That inconsistency can produce varying PutMetricFilter plans.

Why "use the real name" is correct

Nothing in code resolves the literal "CloudTrail/DefaultLogGroup" string (grep confirms it's prompt-only); real values are filled by the refine pass from read-step output. A metric filter must attach to the actual log group, so a made-up name is wrong.

Fix

Align the older guidance with the metric-filter section: "discover the trail's CloudWatch Logs log group in a read step (e.g. from the trail's CloudWatchLogsLogGroupArn) and use that exact, real log group name in fixSteps — do not invent a name."

Prompt-only, one-line change. Typecheck clean.

🤖 Generated with Claude Code


Summary by cubic

Align the CloudWatch logGroupName guidance in the remediation prompt to always use the real log group from a read step. Removes the old "CloudTrail/DefaultLogGroup" placeholder to prevent inconsistent PutMetricFilter plans.

Written for commit e7af1ec. Summary will update on new commits.

Review in cubic

…ix prompt

Cubic follow-up on the metric-filter work: the prompt told the model two
different things about the CloudWatch logGroupName — the new CLOUDWATCH METRIC
FILTERS section said "use the REAL log group from the read step, never a
placeholder", while the older NO-PLACEHOLDERS section said to use a made-up
"CloudTrail/DefaultLogGroup" default. That inconsistency could produce varying
PutMetricFilter plans.

Nothing in code resolves the literal "CloudTrail/DefaultLogGroup" string (real
values are filled by the refine pass from read-step output), so the real log
group is what's needed. Align the older guidance to "discover the trail's
CloudWatch Logs log group in a read step and use that exact name — do not invent
one", matching the metric-filter section.

Prompt-only change; typecheck clean.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented Jun 5, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
comp-framework-editor Ready Ready Preview, Comment Jun 5, 2026 10:41pm
2 Skipped Deployments
Project Deployment Actions Updated (UTC)
app Skipped Skipped Jun 5, 2026 10:41pm
portal Skipped Skipped Jun 5, 2026 10:41pm

Request Review

@vercel vercel Bot temporarily deployed to Preview – app June 5, 2026 22:40 Inactive
@vercel vercel Bot temporarily deployed to Preview – portal June 5, 2026 22:40 Inactive
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 1 file

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Re-trigger cubic

@tofikwest tofikwest merged commit 80d3275 into main Jun 5, 2026
11 checks passed
@tofikwest tofikwest deleted the tofik/metric-filter-loggroup-prompt branch June 5, 2026 22:44
@claudfuen
Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 3.73.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants