feat(tidb): fork catalog/completion/deparse/scope from mysql (PR3a scaffold)#99
Open
feat(tidb): fork catalog/completion/deparse/scope from mysql (PR3a scaffold)#99
Conversation
…sql (PR3a) Mechanical fork with import path renames only — no logic changes. Collation default left at utf8mb4_0900_ai_ci (PR3b will flip to utf8mb4_bin). Packages forked: - tidb/scope/ (1 file) - tidb/deparse/ (5 files) - tidb/catalog/ (120 files) - tidb/completion/ (7 files incl. SCENARIOS) Verification: - go build ./tidb/... — clean - go vet ./tidb/... — clean - go test ./tidb/... -short -count=1 — all passing Prepares the 4 packages for PR3b, which adds TiDB-specific catalog fields, option wiring, collation flip, completion candidates, and container tests. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
8 tasks
rebelice
approved these changes
Apr 21, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Mechanical fork of the four remaining MySQL packages into
tidb/, preparing the ground for PR3b (TiDB-specific behavior). Pure import-path rename — no logic changes, no collation flip, no new fields.Dependency chain that forces these four packages to ship together:
None of the four compile in isolation, so all four must exist before any tests run.
What changed
tidb/scope/(1 file)tidb/deparse/(5 files)tidb/catalog/(120 .go files)tidb/completion/(7 files incl. SCENARIOS)Why this diff is 57k lines
Previous guidance favors ~500-line PRs. A mechanical fork is the pathological exception — splitting four interdependent packages across 4 PRs produces a chain of unmergeable branches that reviewers can't CI independently, which is harder to review, not easier. Reviewers should verify via CI + spot-check on a handful of files (e.g.
tidb/catalog/catalog.go,tidb/deparse/resolver.go), not line-by-line. The behavioral changes land in PR3b, which will be a human-scale diff.Scope guards honored
utf8mb4_0900_ai_ci— PR3b flips toutf8mb4_binmysql/semantic/not forked (no Go package, metadata only)Test plan
go build ./tidb/...cleango vet ./tidb/...cleango test ./tidb/... -short -count=1— all passing (ast, catalog, completion, deparse, parser)Follow-up
PR3b (branch
feat/tidb-catalog-extensions, branched off this commit) adds:utf8mb4_binpingcap/tidb:v8.5.5container tests🤖 Generated with Claude Code