-
Notifications
You must be signed in to change notification settings - Fork 28.9k
[SPARK-13515] Make FormatNumber work irrespective of locale. #11396
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
|
That looks good. Are there other instances where a |
| import org.apache.spark.sql.types._ | ||
| import org.apache.spark.unsafe.types.{ByteArray, UTF8String} | ||
| import java.text.DecimalFormatSymbols | ||
|
|
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.
Nit: this import should be grouped with the other java.text import.
|
I'm wondering if some people may want to use other Locale, such as |
|
@zsxwing This class is the backend for the |
|
@srowen I went through all other uses of |
|
@lgieron I see.Thanks for clarifying. |
|
@srowen I've cleaned up the code as per your comments. |
| package org.apache.spark.sql.catalyst.expressions | ||
|
|
||
| import java.text.DecimalFormat | ||
| import java.text.DecimalFormatSymbols |
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.
Nit: these should be grouped as java.text.{DecimalFormat, DecimalFormatSymbols}
|
Jenkins test this please |
|
Test build #52122 has finished for PR 11396 at commit
|
|
@srowen The build failed due to unrelated test failing (https://issues.apache.org/jira/browse/SPARK-13530). The fix was committed to master an hour ago and now the test passes. |
|
ok to test |
|
Test build #52144 has finished for PR 11396 at commit
|
|
@zsxwing Can you please make Jenkins rerun the tests? |
|
Test build #52145 has finished for PR 11396 at commit
|
|
Test build #52146 has finished for PR 11396 at commit
|
|
Looks good. CC @chenghao-intel to make sure we're not missing anything; I wasn't sure why there was a local |
|
Merged to master |
## What changes were proposed in this pull request? Change in class FormatNumber to make it work irrespective of locale. ## How was this patch tested? Unit tests. Author: lgieron <[email protected]> Closes apache#11396 from lgieron/SPARK-13515_Fix_Format_Number.
What changes were proposed in this pull request?
Change in class FormatNumber to make it work irrespective of locale.
How was this patch tested?
Unit tests.