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

Non-latin characters in results #520

Closed
mvarakin opened this issue Apr 12, 2021 · 11 comments
Closed

Non-latin characters in results #520

mvarakin opened this issue Apr 12, 2021 · 11 comments

Comments

@mvarakin
Copy link

Windows 10 with Russian locale

Sometimes strings come in Russian (this is more less ok, we can deal with it)

2021-04-12 15 46 01

But sometimes strings come in unreadable format

2021-04-12 15 46 07

On the example above there is no way to find default iface among all the list as there is no ID but only description which is unreadable.

@mvarakin
Copy link
Author

mvarakin commented Sep 1, 2021

Hi! Any news here?

@sebhildebrandt
Copy link
Owner

@mvarakin ... i have refactored wmic that it should now support UTF8 characters. As I want to have confirmation that this works before publishing it to npm, can you test all functions on your side? Easiest way would be to close from GitHub and run tests like so:

git clone https://github.com/sebhildebrandt/systeminformation.git
cd systeminformation
npm run test

then go through all tests and see if results are fine on your side.

Thank you in advance!

@Phamier
Copy link

Phamier commented Oct 12, 2021

Nope image
I think the issue goes even deeper. Windows doesn't use UTF-8 for displaying the info, but a localized encoding. For example, if you have a Russian localization turned on, Windows will display this info in Windows-1251 (old ass Russian encoding created before Unicode).
Microsoft will not change such a thing, because backwards compatibly is their first priority.
So... We are screwed... https://www.youtube.com/watch?v=0j74jcxSunY&ab_channel=Computerphile

@sebhildebrandt
Copy link
Owner

@Phamier @mvarakin thank you for testing ... I also got other feedback that this still is a problem. So I made more research and after hours I guess that at least for some (not all) of the commands I can solve the it ... let me work on it again a little bit and then we might see what I can come up with ... Hope that I have time to work on it the next weekend.

@sebhildebrandt
Copy link
Owner

@Phamier @mvarakin ,,, I made some more changes, not sure if I am able to really fix it ... can you test the latest code here from GitHub? Crossing fingers that this brought some improvements ... but maybe I have no chance here because netsh will create output backwards compatible (so no UTF8 ...)

@sebhildebrandt sebhildebrandt added this to In progress in V6 Tasks Oct 26, 2021
@sebhildebrandt
Copy link
Owner

@mvarakin Can you test this one more time? I made a transition to powerShell also for networkInterfaces(). Hope that solves the problem now.

@sebhildebrandt
Copy link
Owner

@mvarakin, @Phamier ... as #610 addressed the same problem and is solved, I assume, that this is also fine. Can you confirm that?

@Phamier
Copy link

Phamier commented Nov 22, 2021

Yes! It's working properly now.
image

@Phamier
Copy link

Phamier commented Nov 22, 2021

It returns wrong iface, but It's a bug of Windows.

@sebhildebrandt
Copy link
Owner

@Phamier thank you for reporting!

@mvarakin
Copy link
Author

Thanks a lot!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

No branches or pull requests

3 participants