From |g@ut|er @end|ng |rom gm@||@com  Sun Sep  8 19:40:54 2019
From: |g@ut|er @end|ng |rom gm@||@com (Laurent Gautier)
Date: Sun, 8 Sep 2019 13:40:54 -0400
Subject: [Rd] =?utf-8?q?Error=3A_package_or_namespace_load_failed_for_?=
	=?utf-8?b?4oCYdXRpbHM=?=
In-Reply-To: <CAF8bMcbCE79NdUHucODvD5ecc8ZWZGPXij73JrHXqx0bU3O5-Q@mail.gmail.com>
References: <CA+JCgN39_YGcPH7xgc+O8qbRaXZcc6=kqBVDcgQyGyBGJmgoCQ@mail.gmail.com>
 <CAF8bMcZfHR9_=ogp93f5_Y+N=scL0p27Urhgx5Mw5zS6WhfAaw@mail.gmail.com>
 <CAF8bMcbCE79NdUHucODvD5ecc8ZWZGPXij73JrHXqx0bU3O5-Q@mail.gmail.com>
Message-ID: <CA+JCgN1MM8+BQbSY1zxDMWsGK4ka2p=bbEvRjZX9a56HLp15MQ@mail.gmail.com>

R_HOME is not the issue, and I believe that R_LIBS is not involved with
packages such as "datasets", "utils", etc...
I suspect that the issue is around dynamic loading of C libraries, as
depending on the way the R shared library is called the issue is absent or
present, but the error reporting from R makes tracking this easy.

Le dim. 8 sept. 2019 ? 13:22, William Dunlap <wdunlap at tibco.com> a ?crit :

> Also, check the settings of R_HOME and/or R_LIBS.
> Bill Dunlap
> TIBCO Software
> wdunlap tibco.com
>
>
> On Sun, Sep 8, 2019 at 9:58 AM William Dunlap <wdunlap at tibco.com> wrote:
>
>> Look at section 6.1 of the R Installation and Admin manual.
>>
>> 6.1 Default packages
>>
>> The set of packages loaded on startup is by default
>>
>> > getOption("defaultPackages")
>> [1] "datasets"  "utils"     "grDevices" "graphics"  "stats"     "methods"
>>
>> (plus, of course, *base*) and this can be changed by setting the option
>> in startup code (e.g. in ~/.Rprofile). It is initially set to the value
>> of the environment variable R_DEFAULT_PACKAGES if set (as a
>> comma-separated list). Setting R_DEFAULT_PACKAGES=NULL ensures that only
>> package *base* is loaded.
>>
>> Changing the set of default packages is normally used to reduce the set
>> for speed when scripting: in particular not using *methods*will reduce
>> the start-up time by a factor of up to two. But it can also be used to
>> customize R, e.g. for class use. Rscript also checks the environment
>> variable R_SCRIPT_DEFAULT_PACKAGES; if set, this takes precedence over
>> R_DEFAULT_PACKAGES.
>> Bill Dunlap
>> TIBCO Software
>> wdunlap tibco.com
>>
>>
>> On Sun, Sep 8, 2019 at 8:42 AM Laurent Gautier <lgautier at gmail.com>
>> wrote:
>>
>>> Hi,
>>>
>>> When starting an embedded R I encounter the following issue under certain
>>> conditions:
>>>
>>> ```
>>> Error: package or namespace load failed for ?utils? in if
>>> (.identC(class1,
>>> class2) || .identC(class2, "ANY")) TRUE else {:
>>>  missing value where TRUE/FALSE needed
>>> ```
>>> (more such errors for grDevices, graphics, and stats)
>>>
>>> And in the end:
>>>
>>> ```
>>> Warning messages:
>>> 1: package ?utils? in options("defaultPackages") was not found
>>> 2: package ?grDevices? in options("defaultPackages") was not found
>>> 3: package ?graphics? in options("defaultPackages") was not found
>>> 4: package ?stats? in options("defaultPackages") was not found
>>> ```
>>>
>>> While the embedded R appears functional, no package can be loaded.
>>>
>>> The erorr message from R (`missing value where TRUE/FALSE needed`)
>>> suggests
>>> that R should be able to catch the underlying issue (I am yet to find
>>> what
>>> it is) earlier and with this make the task of troubleshooting easier.
>>>
>>> Best,
>>>
>>>
>>> Laurent
>>>
>>>         [[alternative HTML version deleted]]
>>>
>>> ______________________________________________
>>> R-devel at r-project.org mailing list
>>> https://stat.ethz.ch/mailman/listinfo/r-devel
>>>
>>

	[[alternative HTML version deleted]]



[Rd] =?utf-8?q?Error=3A_package_or_namespace_load_failed_for_?= =?utf-8?b?4oCYdXRpbHM=?=
Laurent Gautier