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

Health check gives false warnings for Windows users #56

Open
petrenkonikita112263 opened this issue Mar 1, 2024 · 2 comments
Open

Health check gives false warnings for Windows users #56

petrenkonikita112263 opened this issue Mar 1, 2024 · 2 comments
Assignees
Labels
Type: Bug Something isn't working

Comments

@petrenkonikita112263
Copy link

After executing Health check I get 2 warnings (informative):

  • Language encoding could not be detected!
  • System file encoding should be set to UTF-8! Currently using Cp1252.

image

On my W10 yes the default Cp1252, it can be checked from PowerShell

PS C:\WINDOWS\system32> [System.Text.Encoding]::Default


IsSingleByte      : True
BodyName          : iso-8859-1
EncodingName      : Western European (Windows)
HeaderName        : Windows-1252
WebName           : Windows-1252
WindowsCodePage   : 1252
IsBrowserDisplay  : True
IsBrowserSave     : True
IsMailNewsDisplay : True
IsMailNewsSave    : True
EncoderFallback   : System.Text.InternalEncoderBestFitFallback
DecoderFallback   : System.Text.InternalDecoderBestFitFallback
IsReadOnly        : True
CodePage          : 1252

But this is the default (system) encoding https://stackoverflow.com/questions/1826771/encoding-cp1252

And Health Check expects to see UTF-8 that is default for Linux https://unix.stackexchange.com/questions/112216/which-terminal-encodings-are-default-on-linux-and-which-are-most-common

My current (default) configurations of Windows 10 don't break my XWiki. And you can see from screen all settings for XWiki is set to UTF-8.

@petrenkonikita112263 petrenkonikita112263 added the Type: Bug Something isn't working label Mar 1, 2024
@ChiuchiuSorin ChiuchiuSorin self-assigned this Apr 2, 2024
@petrenkonikita112263
Copy link
Author

petrenkonikita112263 commented Apr 26, 2024

Minor update on it: after upgrading to RC-3 and re-scanning, I don't have any more mention regarding System file encoding, but still, I see Language encoding msg.

msedge_LnTg1v6AVq.mp4

I haven't changed anything as configuration for my XWiki instance.

@petrenkonikita112263
Copy link
Author

petrenkonikita112263 commented Apr 29, 2024

Concerning the warning of Language encoding, currently, the Admin Tools recognize it as the NULL value on the Windows side. If I export my configuration via an application, during this I'll get a warning in console

2024-04-29 11:41:50,389 [http-nio-7635-exec-3 - http://localhost:7635/xwiki/rest/admintools/files?files=xwikiConfig&files=xwikiProperties&files=dataProvider&files=logs&from=28-04-2024&to=29-04-2024] WARN  c.x.a.i.d.SecurityDataProvider - Failed to access language or work directory environment variables.

And open the file configuration_json.txt

{security={configurationEncoding=UTF-8, fileEncoding=UTF-8, PWD=null, activeEncoding=UTF-8, LANG=null}, configuration={databaseName=PostgreSQL, osVersion=10.0, usedServerName=Apache Tomcat, javaVersion=21.0.2, xwikiVersion=16.3.0-rc-1, osArch=amd64, tomcatConfPath=D:\apache-tomcat-9.0.84/conf/server.xml, xwikiCfgPath=D:\apache-tomcat-9.0.84/webapps/xwiki/WEB-INF/, usedServerVersion=9.0.84, osName=Windows 10, databaseVersion=16.1}}

I can't find any configuration concerning LANG in XWiki page, moreover there's no line concerning this in xwiki.properties inside section # Environment.

I think this value has to be excluded from the scan and recording into json file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants