Skip to content
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

Intl.NumberFormat("it-IT").format is returning an incorrectly formatted value in 22.12.0 #56134

Closed
dickwyn opened this issue Dec 4, 2024 · 4 comments
Labels
v8 engine Issues and PRs related to the V8 dependency. wrong repo Issues that should be opened in another repository.

Comments

@dickwyn
Copy link

dickwyn commented Dec 4, 2024

Version

v22.12.0

Platform

Darwin dw-msmbp.local 24.1.0 Darwin Kernel Version 24.1.0: Thu Oct 10 21:03:15 PDT 2024; root:xnu-11215.41.3~2/RELEASE_ARM64_T6000 arm64

Subsystem

No response

What steps will reproduce the bug?

const number = 1000.99;
console.log("it-IT:", new Intl.NumberFormat("it-IT").format(number)); // problematic
console.log("pt-BR:", new Intl.NumberFormat("pt-BR").format(number)); // this works correctly, just trying out a different locale

How often does it reproduce? Is there a required condition?

it reproduces every time

What is the expected behavior? Why is that the expected behavior?

1000.99 should be formatted to 1.000,99 with the it-IT locale

What do you see instead?

1000.99 is formatted to 1000,99 with the it-IT locale

Additional information

No response

@juanarbol
Copy link
Member

I don't think we can do much from our side.

That is part of the V8 implementation.

Would you mind to report that in V8?

I proceed to close this issue as this is not in Node.js side.

@juanarbol juanarbol added v8 engine Issues and PRs related to the V8 dependency. wrong repo Issues that should be opened in another repository. labels Dec 4, 2024
@juanarbol juanarbol closed this as not planned Won't fix, can't repro, duplicate, stale Dec 4, 2024
@Diesmon
Copy link

Diesmon commented Dec 5, 2024

@juanarbol The last time the V8 engine was updated was with Node 22.4.0, according to the node changelogs here: https://github.com/nodejs/node/blob/main/doc/changelogs/CHANGELOG_V22.md#commits-9

This bug only appears as of node 22.12.0
This bug does not appear on node 22.11.0

So how does this bug happen suddenly if V8 engine was not raised since then?

Both versions (22.11 and 22.12) output this string when entering this command:
node -p process.versions.v8

12.4.254.21-node.21

So both use the same V8 engine version.

For me this issue should not be closed as of now as it is unclear why this bug appears, at leasts to me.

@richardlau
Copy link
Member

22.12.0 updated to ICU 76.1.

@dickwyn
Copy link
Author

dickwyn commented Dec 6, 2024

i opened a bug on ICU

https://unicode-org.atlassian.net/jira/software/c/projects/ICU/issues/?jql=project%20%3D%20%22ICU%22%20ORDER%20BY%20created%20DESC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
v8 engine Issues and PRs related to the V8 dependency. wrong repo Issues that should be opened in another repository.
Projects
None yet
Development

No branches or pull requests

4 participants