Closed basil closed 2 years ago
Since I doubt we are explicitly setting a character encoding for Java with -Dfile.encoding
, I think Java is just picking up the system's default encoding via /etc/default/locale
. I suspect this used to contain LANG=en_US.UTF-8
but perhaps no longer does?
Since I doubt we are explicitly setting a character encoding for Java with
-Dfile.encoding
, I think Java is just picking up the system's default encoding via/etc/default/locale
. I suspect this used to containLANG=en_US.UTF-8
but perhaps no longer does?
That is absolutley true! Thanks for opening the issue. @smerle33 did start a PR to patch the image in https://github.com/jenkins-infra/packer-images/pull/340/files.
Since it's end of day for him, I'll take over this particular fix right now.
LANG
and LC_ALL
, set to the value C.UTF-8
to all the pod templates on ci.jenkins.io's UI (with puppet agent disabled). The build https://ci.jenkins.io/job/Core/job/jenkins/job/master/4090/console is now able to clone without this issue.Hotfix persisted by https://github.com/jenkins-infra/jenkins-infra/pull/2389, deployed and tested with the following build: https://github.com/jenkins-infra/jenkins-infra/pull/2389
I'm now handing over to @smerle33 for the long term fix in the packer-images (+ removal of my hotfix once shipped).
Thank you for the quick response!
https://github.com/jenkins-infra/packer-images/pull/341 fixes the issue in container image.
Should be good. Being tested in https://ci.jenkins.io/blue/organizations/jenkins/Core%2Fjenkins/detail/master/4105/pipeline and https://ci.jenkins.io/blue/organizations/jenkins/Tools%2Fbom/detail/master/1235/pipeline (before closing the issue)
Confirmed it works! Closing as solved.
Service(s)
ci.jenkins.io
Summary
Git checkouts of Jenkins core are currently failing with the error shown in this build:
This is the case for all builds on the main branch and all PR builds. It seems to be happening on the Linux container agents.
A build from just 20 hours ago worked:
Note that this was also using JGit on Linux container agents. I saw Stephane's message "Improvement and change of image for linux jnlp-maven agents" to the developer mailing list, and I suspect that this has introduced a change in behavior.
I am actually familiar with this "
java.nio.file.InvalidPathException
: Malformed input or input contains unmappable characters" error in Java. It happens when the default character set cannot express a character that is being used. In this case the code base has a directory namedzzz\341\200\200
(Unicode characters escaped in this message for readability, but not escaped in the filename checked into Git) which is intentionally being used to simulate a user with a Unicode character in their username.I suspect that prior to the new image for Linux JNLP Maven agents, the character set being used was UTF-8. I suspect that it may now be ASCII or some other encoding that cannot express the Unicode characters that are in these filenames in Jenkins core:
Reproduction steps
This is reproducible by building https://ci.jenkins.io/job/Core/job/jenkins/job/master/ or any PR.