From mboxrd@z Thu Jan 1 00:00:00 1970 From: Troy Sankey Subject: Re: Colors and progress indicators on buildprocesses Date: Wed, 28 Sep 2016 10:39:53 -0400 Message-ID: <147507359323.2034.4440394895994902168@what> References: <87d5b525ac5a11f0152902458a35120a@riseup.net> <87y42c4a9v.fsf@we.make.ritual.n0.is> <20160928140552.GA30707@jocasta.intra> Mime-Version: 1.0 Content-Type: multipart/signed; protocol="application/pgp-signature"; micalg="pgp-sha256"; boundary="===============1404949923==" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:35767) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bpG1g-0002uV-Qp for guix-devel@gnu.org; Wed, 28 Sep 2016 10:40:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bpG1b-0007jd-QG for guix-devel@gnu.org; Wed, 28 Sep 2016 10:39:59 -0400 Received: from mail-yb0-x231.google.com ([2607:f8b0:4002:c09::231]:34219) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bpG1b-0007jP-Ku for guix-devel@gnu.org; Wed, 28 Sep 2016 10:39:55 -0400 Received: by mail-yb0-x231.google.com with SMTP id e2so6416339ybi.1 for ; Wed, 28 Sep 2016 07:39:55 -0700 (PDT) Content-Disposition: inline In-Reply-To: <20160928140552.GA30707@jocasta.intra> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: John Darrington , ng0 Cc: guix-devel --===============1404949923== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Quoting John Darrington (2016-09-28 10:05:52) > On Wed, Sep 28, 2016 at 09:57:16AM +0000, ng0 wrote: > = > The problem with colors is that the use of colors in build logs crea= tes > very difficult to read logs if you don't filter them. = > = > This is true. But the build logs already dump some VT100 escape sequences, > (for vertical cursor movement). And they also have to be filtered, so = > if we say that colours are not permitted then we are not applying these > rules consistently. This is our chance make things right! Determine if the terminal is interactive [0] and filter escape codes if yes. I've used Arch, and the coloring was pleasant, but primarily I enjoyed the clear (and less buggy) progress bars. For example: $ guix pull = Starting download of /tmp/guix-file.O3WsYp From http://git.savannah.gnu.org/cgit/guix.git/snapshot/master.tar.gz... =E2=80=A6.tar.gz 1.7MiB/s 00:06 | 10= .5MiB transferred The "From" line shows what is about to be downloaded, but the progress par suggests that "=E2=80=A6.tar.gz" is being downloaded. There is a lot of whitespace after that, which is weird. Also, here's a bug: copying and compiling to '/gnu/store/himp5ds1b9m0932dfzxp3gg3vvs7lxd4-g= uix-latest'... loading... 23.1% of 528 filesrandom seed for tests: 1475073161 loading... 99.8% of 528 files Something happens during the loading phase, and the string "random seed for tests: 1475073161" gets printed (also inserting a newline). The progress indicator cannot cope, so it starts on a new line. Also, it stops at 99.8% which is confusing. These non-color issues are more important to resolve, IMO. Troy [0] http://www.tldp.org/LDP/abs/html/intandnonint.html --===============1404949923== MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Description: signature Content-Type: application/pgp-signature; name="signature.asc"; charset="us-ascii" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAABCAAGBQJX69Y2AAoJEIRGmXXw0dCU9Y0P/jELb24uNt7NVSuhQcqVtV77 iybHmudYoTgXwQUSyoaLqJMRe4UDP3Y8nf34LuDMAqVyAhtr4a8CEaUUlUnsnnTi FBghD/W0XsIGZzJPI2IpTtyakO6HC7R5WCzGWX9KyzpamLb7+A9lRHbtQ7c8gMC7 es8l8yFdvyHx/hgKXlenHrIC63/6jW+pVlhOB5nfSKUPTLu4Ug7ViJTAtVLS0iMU O1ohOUGasmHXoTgjPYZ3eCBAJJkn5PfLeWS3/7TOusUZ+8HX1KMuou/pOOv9PHF7 Eo/p32/Cf28HePWl2p1l16rLBTlahtBKIeF+S10tWbgvI+bLYk8EJf+gcJCBXfDX vIdQ8xdYdbBvApK+RvrIChfSC986eelhnQGBe5bC9MyErA+dj2A76D7N43iLU7WM wi0VjiTlMeDJqVov0glQw7v5aLH2bgvAjgKl9ag9/4rMCr1y32GmNm2Cdj7GN3mK pTCl4jjgsfRxVmfSKZJwkNjHl9/3IoHZW/bU1W+/iDxfuGRry9VUjHvGrlzy5JcO R6nmYFCvklC0Cd5Z7N3YyZQcEkE6vAA1a/oOYPGbm1siSQ4dB8/gYE5BJ0//qq6O d82Psgfou7ZQRCRyXwY2BIPfh/9YeF6Hij64ugOB7WSIUusKPL7DDt+4JqIcYKlR cpgbTXE7z0kE33ZAeakn =GY1G -----END PGP SIGNATURE----- --===============1404949923==--