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

fix: coredump: goctl model mysql ddl --src user_base.sql --dir . area… #3777

Merged
merged 4 commits into from
Dec 12, 2023

Conversation

zzZZzzz888
Copy link
Contributor

…/goctl #3766

Root cause:
when column name is not valid in UNIQUE KEY, element in uniqueIndex is nil in function checkDuplicateUniqueIndex() of parser.go file and crash happens

What is fixed
We don't add element to uniqueIndex when the column name of UNIQUE KEY is invalid.
When run command as following,
goctl model mysql ddl --src user_base.sql --dir .

and output below message and exit
"table %s: unique key with error column name[%s]"

Copy link

codecov bot commented Dec 12, 2023

Codecov Report

Merging #3777 (d834c3b) into master (daef970) will increase coverage by 0.01%.
The diff coverage is n/a.

Additional details and impacted files

see 1 file with indirect coverage changes

@kevwan kevwan added this pull request to the merge queue Dec 12, 2023
Merged via the queue into zeromicro:master with commit 4835e4f Dec 12, 2023
6 checks passed
WqyJh pushed a commit to WqyJh/go-zero that referenced this pull request Dec 21, 2023
dongmeng199 pushed a commit to dongmeng199/go-zero that referenced this pull request Dec 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants