The details of the failure are as follows: error: setupterm: could not find terminal File "/var/tmp/portage/www-client/firefox-59.0.2/work/mozilla-release-239e434d6d2b8e1e2b697c3416d1e96d48fe98e5/python/mozbuild/mozbuild/mach_commands.py", line 171, in build mach_context=self._mach_context) ------------------------------------------------------------------- This is an unstable amd64 chroot image at a tinderbox (==build bot) name: 17.0-desktop-gnome_20180425-205446 ------------------------------------------------------------------- gcc-config -l: [1] x86_64-pc-linux-gnu-7.3.0 * Available Python interpreters, in order of preference: [1] python3.5 [2] python2.7 (fallback) Available Ruby profiles: [1] ruby22 (with Rubygems) [2] ruby23 (with Rubygems) * java-config: The following VMs are available for generation-2: 1) IcedTea JDK 3.7.0 [icedtea-8] *) IcedTea JDK 3.7.0 [icedtea-bin-8] Available Java Virtual Machines: [1] icedtea-8 [2] icedtea-bin-8 system-vm emerge -qpv www-client/firefox [ebuild N ] www-client/firefox-59.0.2 USE="dbus gmp-autoupdate pulseaudio screenshot startup-notification -bindist -custom-cflags -custom-optimization -debug -eme-free -hardened -hwaccel -jack (-neon) (-selinux) -system-harfbuzz -system-icu -system-jpeg -system-libevent -system-libvpx -system-sqlite {-test} -wifi" L10N="-ach -af -an -ar -as -ast -az -bg -bn-BD -bn-IN -br -bs -ca -cak -cs -cy -da -de -dsb -el -en-GB -en-ZA -eo -es-AR -es-CL -es-ES -es-MX -et -eu -fa -ff -fi -fr -fy -ga -gd -gl -gn -gu -he -hi -hr -hsb -hu -hy -id -is -it -ja -ka -kab -kk -km -kn -ko -lij -lt -lv -mai -mk -ml -mr -ms -nb -nl -nn -or -pa -pl -pt-BR -pt-PT -rm -ro -ru -si -sk -sl -son -sq -sr -sv -ta -te -th -tr -uk -uz -vi -xh -zh-CN -zh-TW"
Created attachment 528806 [details] emerge-info.txt
Created attachment 528808 [details] emerge-history.txt
Created attachment 528810 [details] environment
Created attachment 528812 [details] etc.portage.tbz2
Created attachment 528814 [details] logs.tbz2
Created attachment 528816 [details] temp.tbz2
Created attachment 528818 [details] www-client:firefox-59.0.2:20180427-174049.log
I get the same error when building packages from systemd's timers unit (empty environment) My theory is the following: - new ncurses now returns an error when TERM variable is not set instead of defaulting to dumb - binaries that rely on TERM to be set fail now It looks like in this case user has to set TERM manually somewhere.
*** Bug 663702 has been marked as a duplicate of this bug. ***
Maybe do something like this in the ebuild or eclass: export TERM=${TERM:-dumb}
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/proj/mozilla.git/commit/?id=10516a58d09b92067afd195622d2b021563582b8 commit 10516a58d09b92067afd195622d2b021563582b8 Author: Ian Stakenvicius <axs@gentoo.org> AuthorDate: 2018-08-15 19:29:35 +0000 Commit: Ian Stakenvicius <axs@gentoo.org> CommitDate: 2018-08-15 19:29:35 +0000 mozcoreconf: attempt workaround for occasional setupterm-based build error Bug: http://bugs.gentoo.org/654316 eclass/mozcoreconf-v6.eclass | 3 +++ 1 file changed, 3 insertions(+)
(In reply to Larry the Git Cow from comment #11) > The bug has been referenced in the following commit(s): > > https://gitweb.gentoo.org/proj/mozilla.git/commit/ > ?id=10516a58d09b92067afd195622d2b021563582b8 So that failed -- the issue is not the TERM variable it seems. setupterm is being called from a python lib 'blessings' that enables pretty-printing; for some unknown reason its not only failing, but the try..catch that looks to surround it to provide a fallback is also not working properly. Working with toralf on this directly via irc, since tinderboxing seems to be the easiest way to reproduce.
got at the unstable amd64 chroot image 17.0-developer_abi32+64_20180831-160502 this too, so attach files here too to help to find the root cause
Created attachment 546208 [details] emerge-info.txt
Created attachment 546210 [details] emerge-history.txt
Created attachment 546212 [details] environment
Created attachment 546214 [details] etc.portage.tbz2
Created attachment 546216 [details] logs.tbz2
Created attachment 546218 [details] temp.tbz2
Created attachment 546220 [details] www-client:firefox-62.0-r1:20180907-204449.log
> TERM="unknown" is your problem. Please fix your setup and set a known/supported TERM. See the bug added to "See also" for more details (for example it is possible that an upgrade in the past went wrong causing TERM=unknown for you). Please re-open is this is still a problem with a known TERM environment variable.
What should be the TERM value if there is not terminal present at all? (cron-based builds)
Some packages using blessing are forcing "linux" or "xterm" for CI runs to workaround this limitation. I am wondering if you have explicit set this to TERM="unknown" on your own? In this case I would say "That's an error caused by an invalid user configuration. What did user expect when setting TERM to something its system doesn't support?" But I just found the following fix: https://github.com/erikrose/blessings/pull/137 So this should be go away in future. Can you tell me if you set this on your own or did you haven't set TERM at all? Maybe I'll add the blessing fix to our Mozilla patch set...
(In reply to Thomas Deutschmann from comment #23) > Can you tell me if you set this on your own or did you haven't set TERM at > all? Answered on my own, I can reproduce with no TERM set. So I'll bump patch set.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=46adb588dc7afaec3745c9672ea481f2302d5e52 commit 46adb588dc7afaec3745c9672ea481f2302d5e52 Author: Thomas Deutschmann <whissi@gentoo.org> AuthorDate: 2018-09-08 13:20:17 +0000 Commit: Thomas Deutschmann <whissi@gentoo.org> CommitDate: 2018-09-08 13:34:18 +0000 www-client/firefox: allow building without TERM being set Link 1: https://bugzilla.mozilla.org/show_bug.cgi?id=1432867 Link 2: https://github.com/erikrose/blessings/pull/137 Closes: https://bugs.gentoo.org/654316 Package-Manager: Portage-2.3.49, Repoman-2.3.10 .../files/firefox-52.9.0-blessings-TERM.patch | 56 ++++++++++++++++++++++ .../files/firefox-60.0-blessings-TERM.patch | 56 ++++++++++++++++++++++ www-client/firefox/firefox-52.9.0.ebuild | 4 +- www-client/firefox/firefox-60.2.0.ebuild | 3 +- www-client/firefox/firefox-62.0-r1.ebuild | 2 + 5 files changed, 119 insertions(+), 2 deletions(-)
*** Bug 665522 has been marked as a duplicate of this bug. ***
Confirmed, calling with TERM= fails.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=61f2b686d018838df528cb143f6fe3458331de5d commit 61f2b686d018838df528cb143f6fe3458331de5d Author: Thomas Deutschmann <whissi@gentoo.org> AuthorDate: 2018-09-09 02:25:40 +0000 Commit: Thomas Deutschmann <whissi@gentoo.org> CommitDate: 2018-09-09 02:43:44 +0000 www-client/firefox: update blessings patch to force TERM value Closes: https://bugs.gentoo.org/654316 Package-Manager: Portage-2.3.49, Repoman-2.3.10 www-client/firefox/files/firefox-52.9.0-blessings-TERM.patch | 2 +- www-client/firefox/files/firefox-60.0-blessings-TERM.patch | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
A bad TERM value like " " or a real bad value (e.g. unsupported terminal) may still cause the same failure but we are not going to catch them all. Unset TERM variable or empty TERM variable must be enough (I hope).