Skip to content

Database governance built for humans and agents — controlling changes and access across every major database.

chore: remove config for uninstalled GitHub apps (SonarCloud, Semantic PR) (#21281)

Danny Xu7c9afc17d6e8
diff --git a/.github/semantic.yml b/.github/semantic.yml
deleted file mode 100644
index 5f10f62b16..0000000000
--- a/.github/semantic.yml
+++ /dev/null
@@ -1,14 +0,0 @@
-enabled: true
-
-# Only check PR title
-titleOnly: true
-
-types:
- - feat
- - fix
- - refactor
- - docs
- - style
- - test
- - chore
- - cherrypick
diff --git a/.sonarcloud.properties b/.sonarcloud.properties
deleted file mode 100644
index 544ef67d42..0000000000
--- a/.sonarcloud.properties
+++ /dev/null
@@ -1,101 +0,0 @@
-# Path to sources
-sonar.sources=.
-
-# Exclude generated code, build artifacts, and dependencies from analysis
-sonar.exclusions=\
- backend/generated-go/**,\
- backend/migrator/migration/**,\
- backend/api/mcp/gen/**,\
- frontend/src/types/proto-es/**,\
- frontend/src/types/iam/permission-generated.ts,\
- proto/gen/**,\
- bytebase-build/**,\
- frontend/node_modules/**,\
- frontend/playwright.config.ts,\
- frontend/src/utils/sql-download/__tests__/goldens/**,\
- scripts/cosmos-repro-dotnet/**,\
- scripts/cosmos-repro-go/**
-
-# Path to tests — identify test files so they are analyzed as tests, not source
-sonar.test.inclusions=\
- action/**/*_test.go,\
- backend/**/*_test.go,\
- backend/**/*_for_tests.go,\
- backend/**/testdata/**,\
- backend/**/test-data/**,\
- backend/common/testcontainer/**,\
- backend/common/yamltest/**,\
- backend/tests/**,\
- frontend/src/**/*.test.ts,\
- frontend/src/**/*.test.tsx,\
- frontend/src/**/*.spec.ts,\
- frontend/src/**/*.spec.tsx,\
- frontend/scripts/**/*.test.mjs,\
- frontend/tests/**
-
-# Source encoding
-sonar.sourceEncoding=UTF-8
-
-# Suppress false-positive security hotspots that travel with the codebase.
-# These have been triaged and confirmed safe. Using sonar.issue.ignore so
-# any fork or downstream SonarCloud scan also benefits.
-sonar.issue.ignore.multicriteria=fp_sync_sql,fp_route_creds,fp_stats_explain,fp_dump_sql,fp_role_sql
-
-# go:S2077 (SQL Injection) in db plugin sync.go files.
-# These files query system catalogs (information_schema, pg_catalog, sys.*) using
-# only hardcoded constants (SystemSchemaWhereClause) or server-side config values
-# (d.databaseName from the Bytebase instance registry). No user input flows in.
-sonar.issue.ignore.multicriteria.fp_sync_sql.ruleKey=go:S2077
-sonar.issue.ignore.multicriteria.fp_sync_sql.resourceKey=backend/plugin/db/*/sync.go
-
-# typescript:S2068 (Hard-coded credentials) in frontend router auth.ts.
-# Route name constants (e.g., "auth.password.reset") contain the word "password"
-# as part of the feature name, not actual credentials.
-sonar.issue.ignore.multicriteria.fp_route_creds.ruleKey=typescript:S2068
-sonar.issue.ignore.multicriteria.fp_route_creds.resourceKey=frontend/src/app/router/routes/auth.tsx
-
-# go:S2077 (SQL Injection) in stats.go files (CountAffectedRows).
-# These run EXPLAIN on user-authored SQL by design — Bytebase is a database
-# change management tool and the user already has execution privileges.
-sonar.issue.ignore.multicriteria.fp_stats_explain.ruleKey=go:S2077
-sonar.issue.ignore.multicriteria.fp_stats_explain.resourceKey=backend/plugin/db/*/stats.go
-
-# go:S2077 (SQL Injection) in db plugin dump.go files.
-# These use d.databaseName from server-side config (Bytebase instance registry)
-# in SHOW CREATE / GET_DDL / USE commands. Not user-supplied input.
-sonar.issue.ignore.multicriteria.fp_dump_sql.ruleKey=go:S2077
-sonar.issue.ignore.multicriteria.fp_dump_sql.resourceKey=backend/plugin/db/*/dump.go
-
-# go:S2077 (SQL Injection) in db plugin role.go files.
-# These use SHOW GRANTS with user/host values from mysql.user or
-# information_schema.user_attributes system catalog tables. Not user input.
-sonar.issue.ignore.multicriteria.fp_role_sql.ruleKey=go:S2077
-sonar.issue.ignore.multicriteria.fp_role_sql.resourceKey=backend/plugin/db/*/role.go
-
-# Exclusions for copy-paste detection.
-# backend/plugin/db/** and the per-engine parser completers are intentionally
-# parallel per-engine implementations (one folder per database engine), so
-# cross-engine similarity is by design, not copy-paste debt.
-# The issue-detail and plan-detail route modules are intentionally parallel
-# (the issue view is the legacy sibling of the plan-first flow); the file
-# pairs below are acknowledged clones of each other, so same-shaped edits to
-# both sides trip new-code CPD without introducing new debt.
-sonar.cpd.exclusions=\
- action/**/*_test.go,\
- frontend/src/routes/project/issue-detail/components/IssueDetailTaskRolloutActionPanel.tsx,\
- frontend/src/routes/project/plan-detail/components/PlanDetailTaskRolloutActionPanel.tsx,\
- frontend/src/routes/project/issue-detail/hooks/useIssueDetailSpecValidation.ts,\
- frontend/src/routes/project/plan-detail/hooks/usePlanDetailSpecValidation.ts,\
- backend/**/*_test.go,\
- backend/**/testdata/**,\
- backend/**/test-data/**,\
- backend/generated-go/**,\
- backend/api/mcp/gen/**,\
- backend/plugin/db/**,\
- backend/plugin/parser/*/completion.go,\
- frontend/src/**/*.test.ts,\
- frontend/src/**/*.test.tsx,\
- frontend/scripts/**/*.test.mjs,\
- frontend/src/app/runtime.ts,\
- frontend/tests/**,\
- proto/gen/**
diff --git a/AGENTS.md b/AGENTS.md
index 7251aab6d6..06e3c708c0 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -221,7 +221,7 @@ The canonical frontend ownership map is in `./frontend/AGENTS.md`. In summary:
## Pull Request Guidelines
-**Before running `gh pr create`, walk through [`docs/pre-pr-checklist.md`](docs/pre-pr-checklist.md).** It covers the breaking-change review, composite-PK query safety, lint/test gates, and SonarCloud properties — the checks that lint and CI can't catch on their own.
+**Before running `gh pr create`, walk through [`docs/pre-pr-checklist.md`](docs/pre-pr-checklist.md).** It covers the breaking-change review, composite-PK query safety, and lint/test gates — the checks that lint and CI can't catch on their own.
- **Code Review** — Follow [Google's Code Review Guideline](https://google.github.io/eng-practices/)
- **Author Responsibility** — Authors are responsible for driving discussions, resolving comments, and promptly merging pull requests
diff --git a/docs/pre-pr-checklist.md b/docs/pre-pr-checklist.md
index bebeb9428d..b9892907d9 100644
--- a/docs/pre-pr-checklist.md
+++ b/docs/pre-pr-checklist.md
@@ -272,16 +272,7 @@ buf lint proto
- For Go changes: `go build -ldflags "-w -s" -p=16 -o ./bytebase-build/bytebase ./backend/bin/server/main.go`
- For new migration files: update `TestLatestVersion` in `backend/migrator/migrator_test.go`
-## 9. SonarCloud Properties
-
-**Skip if:** no new files or directories added.
-
-Update `.sonarcloud.properties` to reflect the latest file structure:
-- `sonar.exclusions` for generated code, build artifacts, dependencies (directory paths)
-- `sonar.test.inclusions` for test file patterns (e.g., `**/*_test.go`)
-- `sonar.cpd.exclusions` to skip copy-paste detection on test files
-
-## 10. Final Verification
+## 9. Final Verification
Before running `gh pr create`:
diff --git a/frontend/scripts/check-frontend-structure.mjs b/frontend/scripts/check-frontend-structure.mjs
index 7aa6225f73..e59b115093 100644
--- a/frontend/scripts/check-frontend-structure.mjs
+++ b/frontend/scripts/check-frontend-structure.mjs
@@ -93,7 +93,6 @@ const agentFiles = [
resolve(frontendRoot, "tests/e2e/AGENTS.md"),
resolve(frontendRoot, "src/modules/agent/AGENTS.md"),
resolve(frontendRoot, "src/modules/sql-editor/AGENTS.md"),
- resolve(repoRoot, ".sonarcloud.properties"),
];
const retiredDocumentationTokens = [
["src", "react"].join("/"),