Skip to content
Back to formatted view

Raw Message

Message-ID: <m2lkolyr2u.fsf@ziti.fhcrc.org>
Date: 2006-09-15T17:31:21Z
From: Seth Falcon
Subject: [Bioc-devel] check failure: prerequisit package does not use NAMESPACE
In-Reply-To: <m23bat2mk3.fsf@ziti.fhcrc.org> (Seth Falcon's message of "Fri, 15 Sep 2006 08:10:04 -0700")

A minor correction:

Seth Falcon <sfalcon at fhcrc.org> writes:
>
> Index: R/gaggle.R
> ===================================================================
> --- R/gaggle.R	(revision 19853)
> +++ R/gaggle.R	(working copy)
> @@ -2,6 +2,8 @@
>  #---------------------------------------------------------------------------------
>  .onLoad <- function (libname, pkgname)
>  {
> +    require("methods")
> +    require("rJava")

Much better to check the return value and give a clear error message.
Something like:

  require("methods") || stop("The methods package is missing, your R is broken")
  require("rJava") || stop("unable to load package 'rJava'")