bkero | Weird. I got a python traceback adding ca-certificates-java on xenial | 01:12 |
---|---|---|
bkero | Adding 'ca-certificates-java' to package-installs.yaml to ubuntu/package-installs.yaml should reproduce | 01:13 |
bkero | UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 15: ordinal not in range(128). I think one of the certificates has an accent in the filename | 01:13 |
bkero | Have y'all seen that before? | 01:15 |
*** owalsh has quit IRC | 01:22 | |
bkero | http://paste.openstack.org/show/615224/ | 01:27 |
bkero | http://bugs.launchpad.net/diskimage-builder/+bug/1684081 | 01:51 |
openstack | Launchpad bug 1684081 in diskimage-builder "UnicodeDecodeError with xenial on custom package-installs" [Undecided,New] | 01:51 |
*** chhavi has joined #openstack-dib | 03:02 | |
*** prometheanfire has quit IRC | 05:25 | |
*** isaacb has joined #openstack-dib | 06:52 | |
*** andreas-f has quit IRC | 07:15 | |
*** andreas-f has joined #openstack-dib | 07:16 | |
*** andreas-f has quit IRC | 07:17 | |
*** isaacb_ has joined #openstack-dib | 07:24 | |
*** isaacb has quit IRC | 07:26 | |
*** isaacb_ has quit IRC | 07:29 | |
*** isaacb_ has joined #openstack-dib | 07:35 | |
*** aparnav has joined #openstack-dib | 08:50 | |
*** owalsh has joined #openstack-dib | 09:28 | |
*** owalsh has quit IRC | 10:19 | |
*** owalsh has joined #openstack-dib | 10:21 | |
*** owalsh has quit IRC | 10:22 | |
*** owalsh has joined #openstack-dib | 10:38 | |
*** owalsh has quit IRC | 10:41 | |
*** owalsh has joined #openstack-dib | 10:43 | |
*** owalsh has quit IRC | 11:59 | |
*** aparnav has quit IRC | 12:06 | |
*** aparnav has joined #openstack-dib | 12:06 | |
*** owalsh has joined #openstack-dib | 12:07 | |
*** owalsh has quit IRC | 12:07 | |
*** owalsh has joined #openstack-dib | 12:07 | |
*** farosas has joined #openstack-dib | 12:09 | |
*** aparnav has quit IRC | 12:11 | |
*** deep-book-gk_ has joined #openstack-dib | 13:24 | |
*** deep-book-gk_ has left #openstack-dib | 13:25 | |
*** isaacb_ has quit IRC | 15:06 | |
openstackgerrit | Markos Chandras (hwoarang) proposed openstack/diskimage-builder master: elements: zypper: Enable explicit sudo logging https://review.openstack.org/483446 | 15:31 |
openstackgerrit | Markos Chandras (hwoarang) proposed openstack/diskimage-builder master: elements: zypper: Enable explicit sudo logging https://review.openstack.org/483446 | 15:33 |
greghaynes | bkero: yea looks like the default locale is probably set to c/ascii not utf8 | 16:07 |
greghaynes | So that's what Python is decoding as | 16:07 |
bkero | greghaynes: Working on trusty though | 16:07 |
bkero | Maybe py2 vs py3 is the diff | 16:08 |
greghaynes | bkero: possible, that would happen is subprocess proc.stdout is not implicitly decoded and wasnt in py2 | 16:12 |
bkero | greghaynes: that seems to be the case | 16:13 |
bkero | I tried proc.stdout.line.decode('utf-8') and it threw back at me that .decode() wasn't a method -- which means it was using py3 | 16:13 |
greghaynes | yea but it could also be that the default locale is set to something utf8 in your trusty build | 16:15 |
greghaynes | the real question is if type(proc.stdout.line) == bytes | 16:15 |
greghaynes | on trusty | 16:15 |
greghaynes | actually, its doing readline | 16:15 |
greghaynes | I think readline has to decode | 16:15 |
greghaynes | so it must be more sane locale | 16:16 |
greghaynes | I think what we should have is an element that tries to set locale to somethign sane in pre-install.d | 16:18 |
greghaynes | probably infer from build host and overridable via env var | 16:18 |
*** saneax has quit IRC | 16:18 | |
*** jamielennox has quit IRC | 16:19 | |
bkero | greghaynes: are pre-install.d scripts sourced so that exported env vars are carried through to other stages? | 16:47 |
greghaynes | env vars exist throughout all stages | 16:47 |
bkero | Sure, but if I have "#!/bin/bash \n\n export THING=true" in script.sh, then do './script.sh', I don't have $THING in my parent environment. | 16:48 |
bkero | I'd need to 'source script.sh' | 16:48 |
bkero | greghaynes: http://paste.openstack.org/show/615299/ | 17:03 |
greghaynes | bkero: not sure what you mean, I mean the same as all the other dib env vars we support for configuration | 17:04 |
greghaynes | except DIB_LOCALE= | 17:05 |
greghaynes | bkero: not sure what the context is in that paste, is somethign different there? | 17:07 |
bkero | greghaynes: That is just DIB_RELEASE=xenial disk-image-create -o temp.qcow2 ubuntu vm java | 17:07 |
bkero | (I made the java element, it just has a package-installs.yaml of 'openjdk-8-headless-jre' | 17:08 |
bkero | ) | 17:08 |
greghaynes | yea, so its just locale | 17:09 |
greghaynes | basically you need to have en_US-utf8 as your locale | 17:09 |
greghaynes | and right now its C | 17:09 |
bkero | In my shell it's en_US.UTF-8. I imagine that needs to be passed in to dib somehow | 17:10 |
greghaynes | yes, which is what I was getting at with making an element that sets it up in pre-install.d. Id also try grepping around to make sure we dont have anything that might try to set it | 17:10 |
greghaynes | I know theres some fedora specific stuff to work around some bugs there, but I dont remember if theres anythign similar on ubuntu | 17:11 |
bkero | only in debootstrap :) | 17:11 |
bkero | and that's C.UTF-8 | 17:11 |
greghaynes | hrm | 17:12 |
greghaynes | I have no idea what debootstrap does with that info | 17:12 |
bkero | My locale.gen stuff | 17:13 |
bkero | Maybe | 17:13 |
greghaynes | do you have a shell inside of the chroot/ | 17:13 |
greghaynes | you should see if locales-all is installed | 17:13 |
bkero | I can drop a shell inside package-installs-v2 | 17:13 |
greghaynes | yea youll just want to make sure you do it as late as possible | 17:14 |
bkero | added 'export LC_ALL=C.UTF-8' to my pre-install.d script, didn't work. Tried en_US.UTF-8 too | 17:14 |
greghaynes | oh sorry - you cant export vars in those phases, only read them | 17:16 |
greghaynes | becasue each script is in a subshell | 17:16 |
bkero | That's what I was saying earlier ._. | 17:16 |
greghaynes | right so the way our env vars all work is in environment.d we export the things that the scripts need | 17:17 |
bkero | I added a pdb set_trace, will go see if there's a locales-all package | 17:17 |
bkero | There is no locales-all package, although the locales package is installed | 17:19 |
greghaynes | also as a quick test, add that export to the package-installs script | 17:19 |
greghaynes | since its script local itd work | 17:20 |
bkero | os.getenv('LC_ALL') is C, and os.getenv('LANG') is en_US.UTF-8 | 17:20 |
bkero | I've never seen LC_ALL and LANG differ before O_o | 17:20 |
greghaynes | yea | 17:21 |
bkero | ok, environment.d/10-locale = 'export LC_ALL=en_US.UTF-8' for starters | 17:21 |
bkero | It's also interpreting newlines weirdly and making the terminal look totally off | 17:22 |
bkero | greghaynes: environment.d fixed it :D | 17:22 |
greghaynes | ok cool so you must have the locales-all pacakge installed | 17:23 |
bkero | Xenial doesn't seem to have a locales-all package | 17:28 |
bkero | at least dpkg -l didn't list it | 17:28 |
bkero | It did have a locales package though, and that was installed | 17:28 |
greghaynes | https://packages.ubuntu.com/xenial/locales-all | 17:33 |
greghaynes | hrm | 17:33 |
greghaynes | OH thats in universe | 17:33 |
greghaynes | yea locales is the one | 17:34 |
greghaynes | cool | 17:34 |
bkero | greghaynes: Does it make sense for that environment.d to live in the element itself, or is this a more generic patch? | 17:38 |
*** jamielennox has joined #openstack-dib | 18:37 | |
greghaynes | bkero: in the element I think | 19:20 |
greghaynes | bkero: well, depends what you mean by generic, I think the generic thing is to make a locale element but it might be worth an ML or similar, im curious what ianw_pto and andreas think | 19:20 |
bkero | Ok, so any other element which adds a dep on ca-certificates to xenial (non-minimal) will hav this problem too | 19:21 |
greghaynes | yea the larger thing is 'locale isnt being properly configured' | 19:21 |
greghaynes | and IIRC thats somethign we have just punted on because it hadnt been a real issue for anyone yet | 19:21 |
greghaynes | but I am not the most up to date on the status of that | 19:21 |
bkero | DIB_LOCALE? | 19:22 |
bkero | *time for ^ | 19:22 |
greghaynes | right, I think wed make an element called locale-config or something, it would use that var or by default check the locale on the build host and properly set it in the target | 19:22 |
*** chhavi has quit IRC | 19:38 | |
openstackgerrit | Dirk Mueller proposed openstack/diskimage-builder master: opensuse-minimal: install glibc-locale https://review.openstack.org/473959 | 20:50 |
openstackgerrit | Dirk Mueller proposed openstack/diskimage-builder master: zypper-minimal: No point in preserving the environment here https://review.openstack.org/483550 | 20:51 |
openstackgerrit | Dirk Mueller proposed openstack/diskimage-builder master: opensuse-minimal: install glibc-locale https://review.openstack.org/473959 | 20:54 |
*** farosas has quit IRC | 21:10 | |
*** saneax has joined #openstack-dib | 22:01 |
Generated by irclog2html.py 2.15.3 by Marius Gedminas - find it at mg.pov.lt!