all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Chris Marusich <cmmarusich@gmail.com>
To: Danny Milosavljevic <dannym@scratchpost.org>
Cc: guix-devel <guix-devel@gnu.org>
Subject: Re: wrong type of agument... where ?
Date: Sat, 06 Jan 2018 17:46:46 -0800	[thread overview]
Message-ID: <87zi5qphix.fsf@gmail.com> (raw)
In-Reply-To: <20180101003918.501ab0c3@scratchpost.org> (Danny Milosavljevic's message of "Mon, 1 Jan 2018 00:39:18 +0100")

[-- Attachment #1: Type: text/plain, Size: 1092 bytes --]

Danny Milosavljevic <dannym@scratchpost.org> writes:

> Try this:
>
> diff --git a/gnu/build/linux-boot.scm b/gnu/build/linux-boot.scm
> index 4dd740174..810a0d63f 100644
> --- a/gnu/build/linux-boot.scm
> +++ b/gnu/build/linux-boot.scm
> @@ -507,7 +507,14 @@ to it are lost."
>               (switch-root "/root")
>               (format #t "loading '~a'...\n" to-load)
>  
> -             (primitive-load to-load)
> +             (catch #t
> +               (lambda ()
> +                 (primitive-load to-load))
> +               (lambda (key . args)
> +                 (format (current-error-port) "Error: ~a: ~a\n" key args)
> +                 (reboot))
> +               (lambda (key . args)
> +                 (display-backtrace (make-stack #t) (current-error-port))))
>  
>               (format (current-error-port)
>                       "boot program '~a' terminated, rebooting~%"
>

In some other languages (e.g., Java, Python), we get stack traces by
default when an unhandled exception is thrown.  Is this not the case in
Guile?

-- 
Chris

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

  parent reply	other threads:[~2018-01-07  1:46 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-31 11:39 wrong type of agument... where ? Catonano
2017-12-31 12:23 ` Danny Milosavljevic
2017-12-31 13:04   ` Catonano
2017-12-31 14:35     ` Danny Milosavljevic
2017-12-31 14:48       ` Catonano
2017-12-31 23:03         ` Catonano
2017-12-31 23:39         ` Danny Milosavljevic
2018-01-01 10:54           ` Catonano
2018-01-01 14:01             ` Danny Milosavljevic
2018-01-07  1:46           ` Chris Marusich [this message]
2018-01-07 10:46             ` Danny Milosavljevic
2018-01-07 23:22               ` Danny Milosavljevic
2018-01-08 18:36                 ` Danny Milosavljevic

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87zi5qphix.fsf@gmail.com \
    --to=cmmarusich@gmail.com \
    --cc=dannym@scratchpost.org \
    --cc=guix-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.