From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: David Pirotte Newsgroups: gmane.lisp.guile.bugs Subject: bug#36677: [PATCH] Don't truncate backtraces Date: Thu, 25 Jul 2019 13:27:57 -0300 Message-ID: <20190725132757.60e2e1cb@capac> References: <20190715202918.92925-1-rob@vllmrt.net> <87ef2ownkf.fsf@netris.org> <20190721195943.096ebac6@capac> <87lfwq52lv.fsf@netris.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/LbjOLAWBVp5NL0d6dcaQgjt"; protocol="application/pgp-signature" Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="109365"; mail-complaints-to="usenet@blaine.gmane.org" Cc: 36677@debbugs.gnu.org, Robert Vollmert To: Mark H Weaver Original-X-From: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Thu Jul 25 18:29:14 2019 Return-path: Envelope-to: guile-bugs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hqgcD-000SIN-C9 for guile-bugs@m.gmane.org; Thu, 25 Jul 2019 18:29:13 +0200 Original-Received: from localhost ([::1]:33860 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hqgcC-0000lA-3A for guile-bugs@m.gmane.org; Thu, 25 Jul 2019 12:29:12 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:38702) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hqgc8-0000l0-3T for bug-guile@gnu.org; Thu, 25 Jul 2019 12:29:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hqgc3-0005WY-3N for bug-guile@gnu.org; Thu, 25 Jul 2019 12:29:05 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:59717) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hqgc2-0005U6-8B for bug-guile@gnu.org; Thu, 25 Jul 2019 12:29:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hqgc2-0000Yq-2z for bug-guile@gnu.org; Thu, 25 Jul 2019 12:29:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: David Pirotte Original-Sender: "Debbugs-submit" Resent-CC: bug-guile@gnu.org Resent-Date: Thu, 25 Jul 2019 16:29:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 36677 X-GNU-PR-Package: guile X-GNU-PR-Keywords: patch Original-Received: via spool by 36677-submit@debbugs.gnu.org id=B36677.15640720892084 (code B ref 36677); Thu, 25 Jul 2019 16:29:02 +0000 Original-Received: (at 36677) by debbugs.gnu.org; 25 Jul 2019 16:28:09 +0000 Original-Received: from localhost ([127.0.0.1]:40304 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hqgbB-0000XY-2L for submit@debbugs.gnu.org; Thu, 25 Jul 2019 12:28:09 -0400 Original-Received: from maximusconfessor.all2all.org ([79.99.200.102]:57528) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hqgb8-0000XN-R8 for 36677@debbugs.gnu.org; Thu, 25 Jul 2019 12:28:07 -0400 Original-Received: from localhost (localhost [127.0.0.1]) by maximusconfessor.all2all.org (Postfix) with ESMTP id 6FF941BE012C; Thu, 25 Jul 2019 18:28:05 +0200 (CEST) Original-Received: from maximusconfessor.all2all.org ([127.0.0.1]) by localhost (maximusconfessor.all2all.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LChz8c41i8-m; Thu, 25 Jul 2019 18:28:05 +0200 (CEST) Original-Received: from capac (unknown [179.210.16.107]) by maximusconfessor.all2all.org (Postfix) with ESMTPSA id 6A3891BE00D3; Thu, 25 Jul 2019 18:28:04 +0200 (CEST) In-Reply-To: <87lfwq52lv.fsf@netris.org> X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; x86_64-pc-linux-gnu) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-guile@gnu.org List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Original-Sender: "bug-guile" Xref: news.gmane.org gmane.lisp.guile.bugs:9410 Archived-At: --Sig_/LbjOLAWBVp5NL0d6dcaQgjt Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Hi Mark, > You can see now that there are pressures coming from both directions > on this issue.=20 I always 'did see' that, my point is that enabling truncated printing should be the default, and that we should be able to 'toggle' that to full printing anytime ... for the repl, errors, and backtraces, The 'toggle' should be made so easy that we could bind it to, say, F8 or another key, then hit it when needed ... not matter how easy is the 'toggle' mechanism though, the default should be, imo, to enable truncated printing for he repl, errors, and backtraces. Fwiw, I recently helped two quite advanced guilers, on #guile, one did ask if he could 'truncate' and how, I pointed to the guile-cv documentation, the other said: "I wish I new this was possible ...". Currently, wrt to errors, it is very difficult, next to impossible, to configure guile to enable truncated printing, and the above user, an advanced guiler, answered, when I also pointed to a complete 'recipe', in the guile-cv doc, '... thanks but I 'm gona get there ...' (or something along the lines, I don't remember the exact words - it was very clear though, that he was afraid to 'just' apply the recipe). It seems, from Robert's email, that it is currently quite difficult, if not impossible, to toggle bactraces to full printing. > (1) Historically, the Guile has never truncated REPL output, and I'm > concerned that changing the default behavior may violate longstanding > user expectations. 'Historically' stands, imo, as an explanation, not as a justification for a 'no change' ... we did change, and it did break user code, from 1.8 to 2.0 ... I don't think this change will break anything, but even though, 2.2 -> 3.0 is 'an opportunity', should we agree of course ...=20 > I, for one, often ask for a moderately large data structure to be > computed and printed at the REPL, and I normally want to see the > whole thing. You are an expert, you know it is possible, you know how ... The persons I am 'targeting' to become guile-cv users are newbies, although highly educated in their domain, they don't know what scheme is, they don't even know the word 'Lisp', they don't understand I have to configure Guile so they can use it ... and tell me, for the very few I could 'sit next to' and configure for them, that they would never ever do that themselves ... not even the 'simple' (simple for us), repl config ... Then as exposed above, even advanced guilers don't know, and when informed 'how to', don't want to 'risk' lots of 'small changes' in (ice-9 boot), which is understandable, I'm not 'jugging' ... > (2) Some software may act as a front-end for the Guile REPL, sending > commands to it and interpreting the output. For example, I believe > that Geiser does this. I'm concerned that changing the default > truncation behavior may cause problems here. I use geiser, and never ever had a problem - but if I would I would have talked to Jao, who's extremely responsive ... and he would have solved the problem, but I never had a single problem: geiser only interprets certain pattern, like guile-cv's output, to display images in emacs ... so truncated print is not a problem at all for geier, afaict at least. > (3) I'm not confident that 'truncated-print' is fully robust for > arbitrary data types. I would need to make a careful audit of the > code. Again, imo, it explains, but does not stand as a justification for a 'no change': we could reuse the backtrace 'trunker', or make truncaped-print robust, I never had a single truncated-print related problem in years though, not a proof, but quite a good 'start' ... > (4) The Guile REPL already provides a way to specify a custom printer, > so there's nothing stopping you from installing 'truncated-print' as > the REPL printer. Imo, no matter how easy it is to change, the default should be to enable truncated printing for the repl, erros and backtraces, then indeed we should have 'dead easy' 'toggle' mechanism for those 'extremely rare' guilers who want (occasionally in my experience, I sometimes do to of course) full print ... > To be honest, the main reason I find lack of truncation painful > sometimes is because Emacs does not cope well with extremely long > lines, to put it mildly. Honestly, that's a flaw in Emacs, and it > seems like it would be better to fix Emacs than to work around it in > Guile by omitting potentially useful information from error reports > by default. I strongly disagree with you: it is a guile and not an emacs problem. But it also is impossible to work in a terminal, just try guile-cv, it won't last minutes that you get totally crasy :) so to speak of course, and wish truncated printing would be enable for the repl, erros and backtraces, by default. I should also add that typical image sizes that 'we' need to process using gule-cv (or open-cv, imagej ...) are not small, made in average of 20 millions+ pixels ... but you may try guile-cv even using small images, in a terminal, it's not workable 'as is ...' David --Sig_/LbjOLAWBVp5NL0d6dcaQgjt Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQEzBAEBCgAdFiEEhCJlRZtBM3furJHe83T9k6MFetcFAl052I0ACgkQ83T9k6MF etem1gf/e0A1ErSOg0IFKWzGnaT+r6FkhgiFKYRKO6K/nSxvKCKlC9UZvQm0M4K/ SPvdz7izBvrukRU2vYksWQXght5blbuPopowQetG/tm7W83clxVC+RiwjB6I93Nh 1BAyXB8nAc/7vFY6YQC0WV6H9S20Wzk/dabr3OEPA+/8STmWbhVIJm6uEaemKjkL fS0auLCToxoaCZpjmSDdu9pwZrNe9gTI88ddYG3exNQcPPUBdDhYS+7f5NPLO0Zh zn6bmN51PGC4hjFXsdqSGJycHeW+Qque8rByyfFsOglZC4VCQ4WAzQL9rCH3gwt1 XDI4cqBDoeREvvUxy9HSX7H7cYnRKg== =Iytg -----END PGP SIGNATURE----- --Sig_/LbjOLAWBVp5NL0d6dcaQgjt--