From hpages at fhcrc.org  Fri Jun  9 19:47:25 2006
From: hpages at fhcrc.org (Herve Pages)
Date: Fri, 09 Jun 2006 10:47:25 -0700
Subject: [Rd] install.packages("C",
 dep=TRUE) does not always install indirect dependencies
In-Reply-To: <44888A83.9090202@stats.uwo.ca>
References: <44887B24.4080808@fhcrc.org> <44888A83.9090202@stats.uwo.ca>
Message-ID: <4489B42D.7030108@fhcrc.org>

Duncan Murdoch wrote:
> On 6/8/2006 3:31 PM, Herve Pages wrote:
>> May be this is the desired behavior, I don't know. Personally, I would
>> think of 'install.packages("C", dep=TRUE)' as a reliable way to get 
>> every
>> packages that C directly or indirectly relies on installed.
>
> This seems rather unreasonable.  If a user asked not to install B's 
> dependencies, and A is not listed as a dependency of C, then I don't 
> think a request to install C and its dependencies should install A.

Hi Duncan,

Maybe the user didn't _ask_ not to install B's deps. Maybe he simply 
made a mistake
(which is easy with 'dep=FALSE' being the default), or maybe this is a 
shared system and
someone else installed B without 'dep=TRUE' or removed A or...
But I realize that there would be a significant extra cost if 
'install.packages("C", dep=TRUE)'
had to check the whole deps tree instead of just checking whether only 
the packages listed
in C's Depends field are already installed (especially when those 
packages _are_ already
installed).
So if checking the whole deps tree can't be done everytime 
'install.packages(..., dep=TRUE)'
is used then may be it could be done on demand e.g. with something 
similar to what
"rpm -Va --nofiles" does on a Linux system (this checks the entire 
system for missing deps).

> Perhaps the installation of B without dependencies was a mistake?  I 
> think an argument could be made that dependencies=TRUE should be the 
> default (as it is when using the corresponding menu item in the 
> Windows GUI).
Yes having 'dependencies=TRUE' as the default would definetly help the
user to keep a system where all deps are satisfied.

Best,

H.

-- 
------------------------
Herv? Pag?s
E-mail: hpages at fhcrc.org
 Phone: (206) 667-5791
   Fax: (206) 667-1319



[Rd] install.packages("C", dep=TRUE) does not always install indirect dependencies
Herve Pages