On 2 August 2016 at 13:12, Duncan Murdoch wrote:
| On 02/08/2016 1:01 PM, Dirk Eddelbuettel wrote:
| >
| > On 2 August 2016 at 11:36, Joshua Ulrich wrote:
| > | Maybe I'm missing something, but isn't that the point of calling
| > | requireNamespace()?  For example:
| > | if (requireNamespace("suggestedPackage"))
| > |   stop("suggestedPackage required but not installed")
| > |
| > | That doesn't seem like a heavy burden for package writers when writing
| > | infrequently used functions in their package.  You could even add the
| > | install.packages command to the error message to instruct users to
| > | install the required package.
| >
| > [...]
| >
| > | I personally would not want install.packages() to install packages I'm
| > | unlikely to actually use.
| > |
| > | It's also not clear to me how importing rarely used functions causes
| > | bloat, but installing all packages for all rarely-used functions does
| > | not cause bloat.
| >
| > Sadly, some people whose advocacy is taken as religous gospel in some
| > circles, particularly beginners, advocate pretty much that: treat Suggests:
| > as Depends: and install it anyway because, hell, why would one tests.
| >
| > I regularly run (large) reverse depends checks against some of my more 
widely
| > used packages and run into this all the time.
| >
| > We (as a community, including CRAN whose gatekeepers I have failed to
| > convince about this on on multiple attempts) are doing this wrong.
| > "Suggests:" really means optionally, rather than unconditionally.  But it
| > would appear that you and I are about to only ones desiring that behaviour.
| 
| I thought I understood Joshua's point (and agreed with it), but you also 
| seem to be agreeing with him and I don't understand at all what you're 
| saying.
| 
| What is "this" in your last paragraph, that you have failed to convince 
| CRAN gatekeepers about?

It is really simple:  Having _both_ Suggests: foo _and_ an unconditonal call
to foo::bar() in the code.

Whereas Josh and I argue that it needs to be conditional on requireNames()
coming back TRUE.

Dirk

-- 
http://dirk.eddelbuettel.com | @eddelbuettel | e...@debian.org

______________________________________________
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel

Reply via email to