Skip to content

Conversation

@garciparedes
Copy link
Contributor

Issue # (if applicable)

Closes #33591

Reason for this change

  • The validation is causing false-positive warning messages when using partial identifiers on CloudWatch Metric expressions supporting them.

Description of changes

  • Update the condition to generate the warning message in order to prevent false-positives when one of the special keywords is used.

Checklist


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

@github-actions github-actions bot added bug This issue is a bug. p2 labels Feb 26, 2025
@aws-cdk-automation aws-cdk-automation requested a review from a team February 26, 2025 16:26
@github-actions github-actions bot added the beginning-contributor [Pilot] contributed between 0-2 PRs to the CDK label Feb 26, 2025
Copy link
Collaborator

@aws-cdk-automation aws-cdk-automation left a comment

Choose a reason for hiding this comment

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

(This review is outdated)

@codecov
Copy link

codecov bot commented Feb 26, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 82.21%. Comparing base (a21190e) to head (1d11712).

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #33592   +/-   ##
=======================================
  Coverage   82.21%   82.21%           
=======================================
  Files         119      119           
  Lines        6876     6876           
  Branches     1162     1162           
=======================================
  Hits         5653     5653           
  Misses       1120     1120           
  Partials      103      103           
Flag Coverage Δ
suite.unit 82.21% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
packages/aws-cdk ∅ <ø> (∅)
packages/aws-cdk-lib/core 82.21% <ø> (ø)

@garciparedes garciparedes force-pushed the fix-cloudwatch-expression-warning branch 2 times, most recently from b3628d0 to b8f781e Compare February 26, 2025 16:50
@garciparedes
Copy link
Contributor Author

Exemption Request: the pull request is updating a warning message so there is nothing to cover on integration tests.

@aws-cdk-automation aws-cdk-automation added the pr-linter/exemption-requested The contributor has requested an exemption to the PR Linter feedback. label Feb 26, 2025
@aws-cdk-automation aws-cdk-automation added pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. labels Feb 26, 2025
@garciparedes garciparedes force-pushed the fix-cloudwatch-expression-warning branch from b8f781e to 10b2d29 Compare February 27, 2025 08:47
…h:UnknownIdentifier warnings (aws#33591)

Signed-off-by: Sergio García Prado <[email protected]>
@garciparedes garciparedes force-pushed the fix-cloudwatch-expression-warning branch from 10b2d29 to c4b93e7 Compare February 27, 2025 10:18
GavinZZ
GavinZZ previously approved these changes Feb 28, 2025
Copy link
Member

@GavinZZ GavinZZ left a comment

Choose a reason for hiding this comment

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

LGTM, thank you!

@GavinZZ GavinZZ added the pr-linter/exempt-integ-test The PR linter will not require integ test changes label Feb 28, 2025
@aws-cdk-automation aws-cdk-automation removed the pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. label Feb 28, 2025
@aws-cdk-automation aws-cdk-automation dismissed their stale review February 28, 2025 23:16

✅ Updated pull request passes all PRLinter validations. Dismissing previous PRLinter review.

@mergify
Copy link
Contributor

mergify bot commented Feb 28, 2025

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@mergify
Copy link
Contributor

mergify bot commented Mar 1, 2025

This pull request has been removed from the queue for the following reason: checks failed.

The merge conditions cannot be satisfied due to failing checks:

You should look at the reason for the failure and decide if the pull request needs to be fixed or if you want to requeue it.

If you want to requeue this pull request, you need to post a comment with the text: @mergifyio requeue

@garciparedes
Copy link
Contributor Author

@Mergifyio requeue

@mergify
Copy link
Contributor

mergify bot commented Mar 3, 2025

requeue

❌ Command disallowed due to command restrictions in the Mergify configuration.

  • sender-permission >= write

@mergify mergify bot dismissed GavinZZ’s stale review March 3, 2025 08:44

Pull request has been modified.

@garciparedes
Copy link
Contributor Author

Hey @GavinZZ, seems like the initial automated merge request failed for some reason. I updated the PR with the latest change. Could you try it again?

@aws-cdk-automation aws-cdk-automation added the pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. label Mar 3, 2025
@garciparedes garciparedes requested a review from GavinZZ March 3, 2025 10:08
GavinZZ
GavinZZ previously approved these changes Mar 3, 2025
@mergify
Copy link
Contributor

mergify bot commented Mar 3, 2025

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@mergify
Copy link
Contributor

mergify bot commented Mar 3, 2025

This pull request has been removed from the queue for the following reason: pull request branch update failed.

The pull request can't be updated

You should look at the reason for the failure and decide if the pull request needs to be fixed or if you want to requeue it.

If you want to requeue this pull request, you need to post a comment with the text: @mergifyio requeue

@aws-cdk-automation aws-cdk-automation removed the pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. label Mar 3, 2025
@mergify
Copy link
Contributor

mergify bot commented Mar 3, 2025

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@GavinZZ
Copy link
Member

GavinZZ commented Mar 3, 2025

@Mergifyio requeue

@mergify
Copy link
Contributor

mergify bot commented Mar 3, 2025

requeue

✅ The queue state of this pull request has been cleaned. It can be re-embarked automatically

@mergify
Copy link
Contributor

mergify bot commented Mar 3, 2025

This pull request has been removed from the queue for the following reason: pull request branch update failed.

The pull request can't be updated

You should look at the reason for the failure and decide if the pull request needs to be fixed or if you want to requeue it.

If you want to requeue this pull request, you need to post a comment with the text: @mergifyio requeue

@mergify mergify bot dismissed GavinZZ’s stale review March 3, 2025 19:29

Pull request has been modified.

@aws-cdk-automation aws-cdk-automation added the pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. label Mar 3, 2025
@mergify
Copy link
Contributor

mergify bot commented Mar 3, 2025

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@mergify mergify bot merged commit 97744e7 into aws:main Mar 3, 2025
20 checks passed
@mergify
Copy link
Contributor

mergify bot commented Mar 3, 2025

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@github-actions
Copy link
Contributor

github-actions bot commented Mar 3, 2025

Comments on closed issues and PRs are hard for our team to see.
If you need help, please open a new issue that references this one.

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildv2Project1C6BFA3F-wQm2hXv2jqQv
  • Commit ID: 1d11712
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 3, 2025
@garciparedes garciparedes deleted the fix-cloudwatch-expression-warning branch June 27, 2025 08:02
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

beginning-contributor [Pilot] contributed between 0-2 PRs to the CDK bug This issue is a bug. p2 pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. pr-linter/exempt-integ-test The PR linter will not require integ test changes pr-linter/exemption-requested The contributor has requested an exemption to the PR Linter feedback.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

cloudwatch: CDK detects false-positive missing identifiers on metric expressions

3 participants