[SPARK-19446][SQL] Remove unused findTightestCommonType in TypeCoercion#16786
[SPARK-19446][SQL] Remove unused findTightestCommonType in TypeCoercion#16786HyukjinKwon wants to merge 1 commit intoapache:masterfrom
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.
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.
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.
Sure, no problem. Please submit a separate PR for it. Thanks!
There was a problem hiding this comment.
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.