unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: Ricardo Wurmus <rekado@elephly.net>
To: 46295@debbugs.gnu.org
Subject: bug#46295: syntax error in package definition leads to misleading error message
Date: Thu, 04 Feb 2021 14:41:56 +0100	[thread overview]
Message-ID: <875z38uezf.fsf@elephly.net> (raw)

In (gnu packages cran) I added a snippet but forgot to quote it
properly.  The snippet looked like this:

  (snippet
   (delete-file "inst/htmlwidgets/lib/jquery.min.js"))

Since this is evaluated right away I got an error as I tried to compile
my Guix source checkout:

   error: failed to load 'gnu/packages/cran.scm': No such file or directory

This error is highly misleading as it implies that
“gnu/packages/cran.scm” could not be found, while the actual error is
that “inst/htmlwidgets/lib/jquery.min.js” does not exist.  This could be
improved by catching 'system-error and reporting the file location
instead of just printing the correct error message without context.

-- 
Ricardo




                 reply	other threads:[~2021-02-04 13:43 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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

  List information: https://guix.gnu.org/

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

  git send-email \
    --in-reply-to=875z38uezf.fsf@elephly.net \
    --to=rekado@elephly.net \
    --cc=46295@debbugs.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 public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).