-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-19446][SQL] Remove unused findTightestCommonType in TypeCoercion #16786
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
Conversation
|
cc @gatorsmile, could you take a look please? |
|
Test build #72308 has finished for PR 16786 at commit
|
|
Could you rename |
|
Also clean up the comments? |
Rename findTightestCommonTypeOfTwo to findTightestCommonType with some comments cleanup Clean up more
c1a2bbb to
66a09ed
Compare
|
Thanks, I just updated and rebased. |
| */ | ||
| def compatibleType(t1: DataType, t2: DataType): DataType = { | ||
| TypeCoercion.findTightestCommonTypeOfTwo(t1, t2).getOrElse { | ||
| TypeCoercion.findTightestCommonType(t1, t2).getOrElse { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In CSVInferSchema.scala, it sounds like we are also calling the same function. Could you check whether we can directly call it, instead of duplicating the code? (I did not read it carefully)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, yea, it appearntly possible for now. But, can I maybe do this in another PR if you think it is fine? It seems possible but I would like to avoid to fix it here simply because of a worry to resolve a conflict in the PR refacorting this code path #16680 and it seems not directly related to the JIRA.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, no problem. Please submit a separate PR for it. Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for bearing with me.
|
Test build #72332 has finished for PR 16786 at commit
|
|
retest this please |
|
LGTM pending test |
|
Test build #72346 has finished for PR 16786 at commit
|
|
Thanks, merging to master! |
|
Thank you @gatorsmile. |
## What changes were proposed in this pull request? This PR proposes to - remove unused `findTightestCommonType` in `TypeCoercion` as suggested in apache#16777 (comment) - rename `findTightestCommonTypeOfTwo ` to `findTightestCommonType`. - fix comments accordingly The usage was removed while refactoring/fixing in several JIRAs such as SPARK-16714, SPARK-16735 and SPARK-16646 ## How was this patch tested? Existing tests. Author: hyukjinkwon <gurwls223@gmail.com> Closes apache#16786 from HyukjinKwon/SPARK-19446.
What changes were proposed in this pull request?
This PR proposes to
findTightestCommonTypeinTypeCoercionas suggested in [SPARK-19435][SQL] Type coercion between ArrayTypes #16777 (comment)findTightestCommonTypeOfTwotofindTightestCommonType.The usage was removed while refactoring/fixing in several JIRAs such as SPARK-16714, SPARK-16735 and SPARK-16646
How was this patch tested?
Existing tests.