Skip to content
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

Cloudwatch: Add linting to restrict imports from core #82538

Merged
merged 4 commits into from
Feb 20, 2024
Merged

Conversation

idastambuk
Copy link
Contributor

@idastambuk idastambuk commented Feb 15, 2024

What is this feature?

Final step of removing FE + BE dependencies on core grafana. Enables linting for CW to prevent core grafana imports

Which issue(s) does this PR fix?:

Fixes #78845

Special notes for your reviewer:

Please check that:

  • It works as expected from a user's perspective.
  • If this is a pre-GA feature, it is behind a feature toggle.
  • The docs are updated, and if this is a notable improvement, it's added to our What's New doc.

@idastambuk idastambuk changed the title Add to lint Cloudwatch: Add linting to restrict imports from core Feb 15, 2024
@idastambuk idastambuk marked this pull request as ready for review February 15, 2024 15:35
@idastambuk idastambuk requested review from a team as code owners February 15, 2024 15:35
@idastambuk idastambuk requested review from gabor, kevinwcyu, njvrzm, diegommm, undef1nd and yangkb09 and removed request for a team February 15, 2024 15:35
@@ -122,7 +122,7 @@ func NewInstanceSettings(httpClientProvider *httpclient.Provider) datasource.Ins
}
}

// cloudWatchExecutor executes CloudWatch requests.
// cloudWatchExecutor executes CloudWatch requests
Copy link
Contributor Author

Choose a reason for hiding this comment

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

to trigger BE checks

Copy link
Contributor

@gabor gabor left a comment

Choose a reason for hiding this comment

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

eslint-part is fine 👍

.golangci.toml Outdated
@@ -67,6 +67,7 @@ files = [
"**/pkg/tsdb/parca/**/*",
"**/pkg/tsdb/tempo/*",
"**/pkg/tsdb/tempo/**/*",
"**/pkg/tsdb/cloudwatch/**/*",
Copy link
Contributor

Choose a reason for hiding this comment

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

i don't know how exactly this thing works, but other datasources have 2 lines each... cloudwatch only 1. is this intentional?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed!

.eslintrc Show resolved Hide resolved
.golangci.toml Outdated Show resolved Hide resolved
idastambuk and others added 2 commits February 15, 2024 18:24
Co-authored-by: Kevin Yu <kevinwcyu@users.noreply.github.com>
Co-authored-by: Kevin Yu <kevinwcyu@users.noreply.github.com>
@idastambuk idastambuk merged commit 5431c51 into main Feb 20, 2024
12 checks passed
@idastambuk idastambuk deleted the lint-cw branch February 20, 2024 13:52
@aangelisc aangelisc modified the milestones: 10.4.x, 11.0.x Feb 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CloudWatch: Enable lint rules to prevent importing from core grafana
5 participants