Re: [R-pkg-devel] How to (conditionally) use an archived package (without Suggests)?
Am Sonntag, 25. Februar 2018, 09:49:13 CET schrieb Marius Hofert: > * checking CRAN incoming feasibility ...Warning: unable to access > index for repository https://github.com/waddella/loon/src/contrib: > cannot open URL 'https://github.com/waddella/loon/src/contrib/PACKAGES' 'Additional_repositories' is meant for R package repositories, it won't work with source code git repos. if a package is in 'Suggests' and can't be found on CRAN or BioC, the additional repos given here are searched for it, but only for it's availability. it won't be installed, CRAN only checks whether it *could* be installed. instead of throwing an error, i would probably fallback to a meaningful default at the beginning of the function code and warn the user about it: if(pkg == "loon" && !requireNamespace("loon", quietly = TRUE)) { pkg == "" warning(paste( "Package 'loon' is unavailable, falling back to the default:", pkg )) } else {} i'm dealing with a similar problem at the moment, the main diffenrence being that i brought it onto myself by outsourcing specific parts (support for several natural languages) of one huge package into several add-on packages, and these add-on packages were rejected from CRAN so i can't make any of them a dependecy. meaning they're not even archived :-D viele grüße :: m.eik -- dipl. psych. meik michalke abt. f"ur diagnostik und differentielle psychologie institut f"ur experimentelle psychologie heinrich-heine-universit"at geb"aude 23.03.00.26| tel +49 (0)211 8113498 40204 d"usseldorf | fax +49 (0)211 8111753 http://www.psycho.hhu.dehttps://reaktanz.de https://rkward.kde.org https://twitter.com/RKWardNet signature.asc Description: This is a digitally signed message part. __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel
[R-pkg-devel] stages of package loading
hi, i'm currently trying to figure out whether it is possible to tell a dependency that it was loaded as a dependency and by which package. the use case is this: - packages A and B both depend on package X - package X can be loaded independently, but checks if A or B are available - when both are missing, X should throw a message - when A or B are already loaded, X should load quietly now i want to load A and B without X falsely informing me that they are missing. i.e., it should be clear to X that A is available and currently being loaded when X itself is loaded as the dependency of A. it seems .onLoad() is not the right place for X to search for A or B, because it always throws the message when the first of both packages is being loaded. any suggestions? viele grüße :: m.eik -- dipl. psych. meik michalke abt. f"ur diagnostik und differentielle psychologie institut f"ur experimentelle psychologie heinrich-heine-universit"at geb"aude 23.03.00.26| tel +49 (0)211 8113498 40204 d"usseldorf | fax +49 (0)211 8111753 http://www.psycho.hhu.dehttps://reaktanz.de https://rkward.kde.org https://twitter.com/RKWardNet signature.asc Description: This is a digitally signed message part. __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel
Re: [R-pkg-devel] How to (conditionally) use an archived package (without Suggests)?
Am Sonntag, 25. Februar 2018, 06:35:52 CET schrieb Dirk Eddelbuettel: > On 25 February 2018 at 11:51, meik michalke wrote: > | 'Additional_repositories' is meant for R package repositories, it won't > | work with source code git repos. if a package is in 'Suggests' and can't > | be found > You missed the part where we create packages ("R CMD build") out of source > repos, and then place those packages in package repos. That is what drat is > for. maybe you missed the part where the OP tried to use https://github.com/waddella/loon in 'Additional_repositories'? AFAIK you can't use a simple git source code repository of a package. i'm maintaining various alternative repos myself ( https://reaktanz.de/R/ ; https://files.kde.org/rkward/R/ ; https://undocumeantit.github.io/repos/l10n/ ) using roxyPackage instead of drat. > And with Additional_repositories, it plays with the install.packages() and > update.packages() functions just as it should -- because package dependency > resolution is a powerful mechanism we like to use whereever possible. do you mean that a dependency is automatically fetched and installed from an *alternative* repo configured via 'Additional_repositories'? i didn't get that to work. i only ever managed CRAN to see that the package is there during checks, but not install it. take the 'sylly' package: https://cran.r-project.org/package=sylly it has Additional_repositories: https://undocumeantit.github.io/repos/l10n in its DESCRIPTION and suggests 'sylly.de', 'sylly.en', and 'sylly.es'. but when i run install.packages("sylly", dependencies=TRUE) i get: Warning: dependencies ‘testthat’, ‘sylly.de’, ‘sylly.en’, ‘sylly.es’ are not available am i missing something? viele grüße :: m.eik -- dipl. psych. meik michalke abt. f"ur diagnostik und differentielle psychologie institut f"ur experimentelle psychologie heinrich-heine-universit"at geb"aude 23.03.00.26| tel +49 (0)211 8113498 40204 d"usseldorf | fax +49 (0)211 8111753 http://www.psycho.hhu.dehttps://reaktanz.de https://rkward.kde.org https://twitter.com/RKWardNet signature.asc Description: This is a digitally signed message part. __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel
Re: [R-pkg-devel] stages of package loading
Am Sonntag, 25. Februar 2018, 12:38:35 CET schrieb meik michalke: > now i want to load A and B without X falsely informing me that they are > missing. i.e., it should be clear to X that A is available and currently > being loaded when X itself is loaded as the dependency of A. > > it seems .onLoad() is not the right place for X to search for A or B, > because it always throws the message when the first of both packages is > being loaded. any suggestions? don't bother, i've decided to unsubscribe again and look somewhere else :: m. -- dipl. psych. meik michalke abt. f"ur diagnostik und differentielle psychologie institut f"ur experimentelle psychologie heinrich-heine-universit"at geb"aude 23.03.00.26| tel +49 (0)211 8113498 40204 d"usseldorf | fax +49 (0)211 8111753 http://www.psycho.hhu.dehttps://reaktanz.de https://rkward.kde.org https://twitter.com/RKWardNet signature.asc Description: This is a digitally signed message part. __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel