Weird failure in a build job (Python egg -> RPM)

12 views
Skip to first unread message

Peter Berghold

unread,
Aug 8, 2017, 11:05:24 AM8/8/17
to Jenkins Users
I have a Python egg that I'm trying to repackage into an RPM for a custom installation path. When the build is run manually it goes off without a hitch. 

When the build is run within Jenkins (which is my preferred method) the build fails with a oddball Unicode error. 

I know this is not a Python forum, but I'm in hopes someone in the Jenkins community has seen this and has a fix for it....

error noted -----
Traceback (most recent call last): File "setup.py", line 72, in <module> "ipaddress", File "/opt/ncs/lib/python3.6/distutils/core.py", line 148, in setup dist.run_commands() File "/opt/ncs/lib/python3.6/distutils/dist.py", line 955, in run_commands self.run_command(cmd) File "/opt/ncs/lib/python3.6/distutils/dist.py", line 974, in run_command cmd_obj.run() File "/opt/ncs/lib/python3.6/site-packages/setuptools/command/bdist_rpm.py", line 19, in run orig.bdist_rpm.run(self) File "/opt/ncs/lib/python3.6/distutils/command/bdist_rpm.py", line 283, in run "writing '%s'" % spec_path) File "/opt/ncs/lib/python3.6/distutils/cmd.py", line 335, in execute util.execute(func, args, msg, dry_run=self.dry_run) File "/opt/ncs/lib/python3.6/distutils/util.py", line 301, in execute
func(*args) File "/opt/ncs/lib/python3.6/distutils/file_util.py", line 236, in write_file f.write(line + "\n") UnicodeEncodeError: 'ascii' codec can't encode character '\U0001f44b' in position 2671: ordinal not in range(128)  

Thoughts anybody? 

Mark Waite

unread,
Aug 8, 2017, 11:20:55 AM8/8/17
to Jenkins Users
Possibly you have a different locale setting in the context of your Jenkins job than you have in the context where it works?

LC_ALL or LANG or ...

Mark Waite

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CAArvnv2eCTJrU37mjAj8K2SEkawt67%3D2DvotxG2NEgbfUdbb8A%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Peter Berghold

unread,
Aug 8, 2017, 11:26:34 AM8/8/17
to Jenkins Users
DOH!  why didn't I think of that! :-)  Thanks Mark... going to give that a try...

Reply all
Reply to author
Forward
0 new messages