Skip to content

[SPARK-37941][SQL] Use error classes in the compilation errors of casting#35292

Closed
ivoson wants to merge 3 commits intoapache:masterfrom
ivoson:SPARK-37941
Closed

[SPARK-37941][SQL] Use error classes in the compilation errors of casting#35292
ivoson wants to merge 3 commits intoapache:masterfrom
ivoson:SPARK-37941

Conversation

@ivoson
Copy link
Contributor

@ivoson ivoson commented Jan 23, 2022

What changes were proposed in this pull request?

Migrate the following errors in QueryCompilationErrors onto use error classes:
upCastFailureError
unsupportedAbstractDataTypeForUpCastError
cannotUpCastAsAttributeError

Why are the changes needed?

Porting casting errors to new error framework.

Does this PR introduce any user-facing change?

No

How was this patch tested?

Existing UT.

@ivoson
Copy link
Contributor Author

ivoson commented Jan 23, 2022

cc @MaxGekk

Since there are some existing test cases in EncoderResolutionSuite, I am wondering whether we would like to move all compilation error cases to one test Suite. If we do that, the test file could be pretty big.

@HyukjinKwon HyukjinKwon changed the title [Spark-37941][SQL] Use error classes in the compilation errors of casting [SPARK-37941][SQL] Use error classes in the compilation errors of casting Jan 24, 2022
@AmplabJenkins
Copy link

Can one of the admins verify this patch?

@MaxGekk
Copy link
Member

MaxGekk commented Jan 24, 2022

I am wondering whether we would like to move all compilation error cases to one test Suite.

We should add a test per every error class.

If we do that, the test file could be pretty big.

Need to try to reduce the number of error classes. For example, #35272

@ivoson
Copy link
Contributor Author

ivoson commented Jan 24, 2022

Thanks @MaxGekk . Will add the test case.

@ivoson
Copy link
Contributor Author

ivoson commented Jan 30, 2022

Closing and open another PR #35366

@ivoson ivoson closed this Jan 30, 2022
@ivoson ivoson deleted the SPARK-37941 branch February 3, 2022 13:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Comments