-
-
Notifications
You must be signed in to change notification settings - Fork 31.6k
Regression in Intl.NumberFormat for the nb-NO locale #39056
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Comments
Same for me, just to add another bit of detail:
Expected:
Actual
|
cc @nodejs/i18n-api |
The result is correct. Engines return the same value:
You can also check that the same value is mentioned in the CLDR data: https://unicode-org.github.io/cldr-staging/charts/latest/verify/numbers/nb.html If the value has changed recently, that must be because of an update in the CLDR data. If you feel that this is incorrect, please file an issue for CLDR. |
I think you misread the issue, the issue is that there isn't a space and instead there's a comma. This reproduces for me on Node 16.0. This is probably because of the ICU 69.1 upgrade, which included some major changes to how Norwegian is handled (http://cldr.unicode.org/index/downloads/cldr-39) |
yes, and i'm wondering if there was a packaging issue in v8. Investigating… |
Welcome to Node.js v16.3.0.
Type ".help" for more information.
> (new Intl.NumberFormat('no', { style: 'decimal' })).format(200_000)
'200 000'
> (new Intl.NumberFormat('nb', { style: 'decimal' })).format(200_000)
'200,000'
> (new Intl.NumberFormat('nn', { style: 'decimal' })).format(200_000)
'200 000'
> process.versions.v8
'9.0.257.25-node.16' fishy |
> new Intl.DateTimeFormat("nb").resolvedOptions().locale
'en-US' seems like a v8 problem |
i'll double check that ICU is working properly. |
Note that this also reproduces with 14.17.1 but not with 14.17, which was also upgraded to ICU 69.1 |
Yeah, my bad. Let me look deeper. Thanks @srl295 |
Updated engine versions and @srl295 wait right, at the very least, this is a V8 problem.
|
Can you pass it on to v8 or need me to? |
@srl295 I'll file an issue on V8 |
https://bugs.chromium.org/p/v8/issues/detail?id=11897, closing this issue. |
This has been fixed on V8 a while ago, sadly we're not doing backmerges to older V8 versions.
|
I think this is related to #45784. I noted that we did update V8 in Node.js 16 in Node.js 16.9.0. |
Darwin Kernel Version 20.3.0: Thu Jan 21 00:07:06 PST 2021; root:xnu-7195.81.3~1/RELEASE_X86_64 x86_64
What steps will reproduce the bug?
(new Intl.NumberFormat('nb-NO', { style: 'decimal' })).format(200_000)
Run the above command in Node 16.
How often does it reproduce? Is there a required condition?
Every time.
What is the expected behavior?
Output of:
'200 000'
(Reproduces in Node 15.14.0)
What do you see instead?
Output of:
'200,000'
Additional information
The text was updated successfully, but these errors were encountered: