nodejs / i18n

The Node.js Internationalization Working Group โ€“ A Community Committee initiative.
MIT License
150 stars 40 forks source link

Expand translations to Node.js builtin error messages #104

Closed targos closed 1 year ago

targos commented 6 years ago

I briefly talked about this with @obensource at JSConf EU. Opening an issue now so I don't forget about it :)

If it is something that this group would like to do, I'm willing to help with the technical work that would have to be done in Node core so that builtin error messages can be translated.

zeke commented 6 years ago

Interesting!

What would be the use of the translated error messages? Are you imagining a future where Node.js itself is internationalized, and developers can install the node runtime in different languages?

As far as enabling translation for these messages, the only requirement would be that there's a way to programmatically collect all the message strings from the nodejs/node repository and give them uniquely identifying names. They could be stored in nodejs/i18n as YML, JSON, or any other structured format.

zeke commented 6 years ago

As I recall in a blog post by @jasnell, there was recently some effort to standardize / constantize all of node's error messages, right?

jasnell commented 6 years ago

We have been in the process of assigning codes to all errors. I'm not sure if we'll ever get to a point where we are shipping translated binaries but having the docs for each code localized would be fantastic.

vanessayuenn commented 6 years ago

I would like to point out that while well intended, translating error messages without assigned error codes might actually do more harm than good. When people encounter an error that they don't quite understand, most likely they'd just copy & paste the error message into search engines. Having translated error messages essentially limits developers' debug resources to only the language of said error messages. But if they also come with standardized error codes, then at least developers can refer back to English resources if need be.

I can 100% get behind this ๐Ÿ‘‡, though.

having the docs for each code localized would be fantastic.

ryo-a commented 6 years ago

now I'm working for a programing education service in Japan. (just a part-time job) As I see, untranslated error messages are sometimes big hurdles for non-native students. so I strongly agree to expand translations ๐Ÿ‘

also I agree to @vanessayuenn 's comment. "googleability" is crucial.

FranzDeCopenhague commented 6 years ago

Providing a tool to support a localized error message lookup may help users meanwhile. For example, see https://www.microsoft.com/en-us/language/Emt

zeke commented 6 years ago

https://www.microsoft.com/en-us/language/Emt

โ˜๏ธthat looks interesting. Have you actually used that @FranzDeCopenhague?

I'm willing to help with the technical work that would have to be done in Node core

@targos can you summarize how you think this would be done?

FranzDeCopenhague commented 6 years ago

@zeke I did not use it recently, but it is part of Microsoft language tools https://www.microsoft.com/en-us/language/Toolbox

zeke commented 6 years ago

Sorry didn't meant to close.

alexandrtovmach commented 4 years ago

It's sounds like something interesting. Do we have any plans/progress with that?

chwan97 commented 3 years ago

we need print the error message to our customer, untranslated message confuse them, wish node's error output support i18n.

Trott commented 1 year ago

I've unarchived this repo so I can close all PRs and issues before re-archiving.