Skip to content

chore(maintenance): migrate metrics utility to biome #2816

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

Merged
merged 6 commits into from
Jul 24, 2024

Conversation

daschaa
Copy link
Contributor

@daschaa daschaa commented Jul 23, 2024

Summary

Changes

Closes #2799

Issue number: closes #2799


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Disclaimer: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.

@daschaa daschaa requested a review from a team July 23, 2024 13:34
@daschaa daschaa requested a review from a team as a code owner July 23, 2024 13:34
@pull-request-size pull-request-size bot added the size/L PRs between 100-499 LOC label Jul 23, 2024
@boring-cyborg boring-cyborg bot added dependencies Changes that touch dependencies, e.g. Dependabot, etc. internal PRs that introduce changes in governance, tech debt and chores (linting setup, baseline, etc.) metrics This item relates to the Metrics Utility tests PRs that add or change tests labels Jul 23, 2024

This comment was marked as outdated.

@github-actions github-actions bot added do-not-merge This item should not be merged need-issue This PR needs an issue before it can be reviewed/worked on further labels Jul 23, 2024
@dreamorosi
Copy link
Contributor

No related issues found. Please ensure there is an open issue related to this change to avoid significant delays or closure.

Sorry about this @daschaa - we need to improve our automation (I'm working on that on the side) to better detect linked issues.

In the meantime, as a workaround - if you want to avoid the bot nagging you - you could edit/write the PR body with the issue number like here (I edited your comment to fix it) 😁

@daschaa
Copy link
Contributor Author

daschaa commented Jul 23, 2024

@dreamorosi I think with this regex the automation might work (at least i get good matches):

\b\*{0,2}[iI]ssue [nN]umber\*{0,2}:\*{0,2}\s*(?<closingWord>closes?|closed|fix|fixes?|fixed|resolves?|resolved)*?\s*#*(?<issue>\d+)\b
  1. I added a * to the closing word
  2. I added a * to the hashtag before the issue number

@dreamorosi dreamorosi removed do-not-merge This item should not be merged need-issue This PR needs an issue before it can be reviewed/worked on further labels Jul 23, 2024
Copy link
Contributor

@dreamorosi dreamorosi left a comment

Choose a reason for hiding this comment

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

Thank you for the work on this.

I have left only one other comment, but seems we are going in the right direction.

We'll have to do something about all the // biome-ignore lint/complexity/useLiteralKeys but since it'll likely require a refactor of either the tests or the utility we will address this separately (same for Logger).

@dreamorosi
Copy link
Contributor

@daschaa - I just saw there are two Sonar findings.

They are not areas you've touched, but the way the tool works is that it runs on files that were edited as part of the PR, and scans them. So that's why they're coming up now.

@daschaa
Copy link
Contributor Author

daschaa commented Jul 23, 2024

@daschaa - I just saw there are two Sonar findings.

I'll check them :) Sorry that I did not catch them earlier. I guess the checkmark icon in the sonar report just let's my brain ignore the report. 😄

Copy link

@dreamorosi dreamorosi self-requested a review July 24, 2024 07:57
Copy link
Contributor

@dreamorosi dreamorosi left a comment

Choose a reason for hiding this comment

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

Thank you so much for the work on this PR!

We're going to merge this for now, despite the addition of lint/complexity/useLiteralKeys in the unit tests. We have another conversation ongoing in #2821 to make changes that we hope will allow us to remove most/all of the suppressions (thank you for opening the issue 😉).

@dreamorosi dreamorosi merged commit 231c39e into aws-powertools:main Jul 24, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Changes that touch dependencies, e.g. Dependabot, etc. internal PRs that introduce changes in governance, tech debt and chores (linting setup, baseline, etc.) metrics This item relates to the Metrics Utility size/L PRs between 100-499 LOC tests PRs that add or change tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Maintenance: add biome to project (metrics)
2 participants