From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Matt Wette Newsgroups: gmane.lisp.guile.user Subject: Re: excpetion printing Date: Tue, 20 Apr 2021 18:18:13 -0700 Message-ID: References: <982f427b-1c27-1417-010e-67c91bc36100@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="12555"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 To: guile-user@gnu.org Original-X-From: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Wed Apr 21 03:18:46 2021 Return-path: Envelope-to: guile-user@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lZ1Vt-0003A1-AY for guile-user@m.gmane-mx.org; Wed, 21 Apr 2021 03:18:45 +0200 Original-Received: from localhost ([::1]:45724 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lZ1Vs-0001ih-Dr for guile-user@m.gmane-mx.org; Tue, 20 Apr 2021 21:18:44 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:36184) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lZ1VU-0001hr-SR for guile-user@gnu.org; Tue, 20 Apr 2021 21:18:24 -0400 Original-Received: from mail-pf1-x433.google.com ([2607:f8b0:4864:20::433]:37446) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lZ1VR-0008W5-Id for guile-user@gnu.org; Tue, 20 Apr 2021 21:18:20 -0400 Original-Received: by mail-pf1-x433.google.com with SMTP id y62so3256957pfg.4 for ; Tue, 20 Apr 2021 18:18:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding:content-language; bh=oUPD1lm+f+PTGjstfAbgIIDiJ96Y+OooMKOp5uvRd5g=; b=F3FW7VIKyxSDcw48U4rBp4Z9OPtMOag555OuSpQLQuVodxLS4QBfk9WqYIrLtDkQL5 w1Zv0Lh2tHta2Sb6NI7gjaMJ8vOl1RJDu6bcxd7+SSrdGA3GN4J253ShjtqYfkZw9SbX FgAmralLA2Uzg3IWpEPhIj8SvvwDwH6KLlWCQK9usWqo/FaiPSrb7V/7sxhS/Uj4HU05 sd7KU/vaf0RY3dGFJhd1/sRmr6TXswAMYo5bOzqCyVhRF8a2FCyZMy7pjm6IXuzrz4WZ a7/3V8EK1MgONmhdhtpIKJhe+l07ckL6O/DSaOTnqowIvGSmcfAZP+W2ZGDNPrUBrQ9n +JTw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=oUPD1lm+f+PTGjstfAbgIIDiJ96Y+OooMKOp5uvRd5g=; b=H/0bQw/T6H91eSKl7//f/n4eOao3AbVn8Xm3DpZpzTH6X7omLdbkZWL5Q0OHkXuXZ3 h52RWLnsWch+3x3NOOR+1jfOD9ivVTEqXTBn+DtmuoT8vCcvmNXOHA6h+COfvSDZddFr g94TVyu4eXy1w70AsGL6+rlOabd2vdRKmkLvziAHqhlmvKY3rP9vzZHSvVFLC7KJEkpk 9l8aogWc+xOyYN8sQzlT6SOtw9yuU57p7h5GNfLLCw9oyayFvYC7WewonAeWFEg7Cq+C I8ZmE42Byz+8I/dpV2+Aow9loyUpkDHmsWAmVw708e5XjwErlOUn+58laRM60p85inMV VBKA== X-Gm-Message-State: AOAM530ZmrPNY7rlhMDf5sSw9Xga1Y60cEtQoSJjbhEkL63Jc6phajS2 e6yWoDWZhMO3IiLFNLbjQc0E5+wLvfg= X-Google-Smtp-Source: ABdhPJyxWELJfIqem9kL0osqlcQqBZTa8lq3x3l80uaq0XKDsHqJhGGwLBFw9G1Ebx+eNdE9P0bKHA== X-Received: by 2002:a63:c14c:: with SMTP id p12mr19593842pgi.417.1618967895279; Tue, 20 Apr 2021 18:18:15 -0700 (PDT) Original-Received: from [192.168.2.126] (64-52-176-132.championbroadband.com. [64.52.176.132]) by smtp.gmail.com with ESMTPSA id f18sm220954pfk.144.2021.04.20.18.18.14 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 20 Apr 2021 18:18:14 -0700 (PDT) In-Reply-To: <982f427b-1c27-1417-010e-67c91bc36100@gmail.com> Content-Language: en-US Received-SPF: pass client-ip=2607:f8b0:4864:20::433; envelope-from=matt.wette@gmail.com; helo=mail-pf1-x433.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, NICE_REPLY_A=-0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Original-Sender: "guile-user" Xref: news.gmane.io gmane.lisp.guile.user:17431 Archived-At: On 4/20/21 5:43 PM, Matt Wette wrote: > Is there any error I can throw in Guile that I don't catch myself > but will result in a user-friendly error message at the top?  Not this: > > Throw to key `misc' with args `("read-yaml-file" "file not found: ~S" > ("demo1x.yml") #f)'. > > I did get this: yaml.scm:37:4: In procedure read-yaml-file: ERROR:   1. &message: "read-yaml-file: can't access file:demo1x.yml using guile 3.0 from (cond-expand  (guile-3   (use-modules (ice-9 exceptions))   (define (file-not-found filename)     (raise-exception      (make-exception-with-message       (string-append "read-yaml-file: can't access file:"              filename)))))  (else   (define (file-not-found filename)     (scm-error 'misc "read-yaml-file"            "file not found: ~S" (list filename) #f))))