Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

WISH: Clarify "BiocManager.check_repositories" message and silence it in more cases?

Open
#144 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
r
Domain
tooling

Research direction

Start with R/repositories.R, especially the repository-checking code linked in the issue, and read ?BiocManager::repositories. Compare the message condition, the BiocManager.check_repositories option, accepted repositories, and the requested environment-variable behavior. Done means the intended message, documentation, and silencing behavior are agreed and covered by appropriate tests.

Written by the indexing model from the issue text.

Description

Issue

It is not always clear why the following message appear:

'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details
replacement repositories:
CRAN: https://cloud.r-project.org

For instance, it shows up in the middle of a package installation when checking on R-hub, e.g.

* installing *source* package 'pillar' ...
** package 'pillar' successfully unpacked and MD5 sums checked
** using staged installation
** R
** inst
** byte-compile and prepare package for lazy loading
'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details
replacement repositories:
CRAN: https://cloud.r-project.org
** help
*** installing help indices
*** copying figures
** building package indices
'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details
replacement repositories:
CRAN: https://cloud.r-project.org
** installing vignettes
** testing if installed package can be loaded from temporary location
'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details
replacement repositories:
CRAN: https://cloud.r-project.org
** testing if installed package can be loaded from final location
'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details
replacement repositories:
CRAN: https://cloud.r-project.org
** testing if installed package keeps a record of temporary installation path
* creating tarball
packaged installation of 'pillar' as 'pillar_1.8.1_R_x86_64-pc-linux-gnu.tar.gz'
* DONE (pillar)

Suggestions

Suggestion 1: Clarify help location

Improve the message to clarify in which package the help is from + use full stop and capitalize next sentence, e.g.

'getOption("repos")' replaces Bioconductor standard repositories, see
'?BiocManager::repositories' for details.
Replacement repositories:
CRAN: https://cloud.r-project.org

or even

'getOption("repos")' replaces Bioconductor standard repositories, see
'help("repositories", package = "BiocManager")' for details.
Replacement repositories:
CRAN: https://cloud.r-project.org
Suggestion 2: Explain why

It is also not clear from the message why it is shown. For example, does it try to warn me about something, and if so, why? Or is it just an FYI message?

Maybe the message itself can be improved, or the paragraph in ?BiocManager::repositories could be extended.

Suggestion 3: Is the help page up-to-date on this?

From

https://github.com/Bioconductor/BiocManager/blob/7e3f92cb78472051712571b070f155f4516fa23d/R/repositories.R#L21-L37

it looks like this is a message condition and not a warning condition. However, in ?BiocManager::repositories there is a mentioning of a "warning":

If alternative default repositories are known to provide appropriate versions of CRAN or Bioconductor packages, the warning may be silenced (displayed as a message) with options(BiocManager.check_repositories = FALSE).

Also, the end of the same paragraph says:

A message is still printed, to serve as a reminder when debugging problems related to incompatible package installation.

Is that correct? Looking at the code, it looks like the note is only generated if R option BiocManager.check_repositories is TRUE.

Suggestion 4: Add all known CRAN repositories to the acceptance list

Could https://cloud.r-project.org, and all other known CRAN mirrors:

> m <- getCRANmirrors(all = FALSE, local.only = FALSE)
> str(m)
'data.frame':	99 obs. of  9 variables:
 $ Name       : chr  "0-Cloud [https]" "Argentina (La Plata)" "Australia (Canberra) [https]" "Australia (Melbourne 1) [https]" ...
 $ Country    : chr  "0-Cloud" "Argentina" "Australia" "Australia" ...
 $ City       : chr  "0-Cloud" "La Plata" "Canberra" "Melbourne" ...
 $ URL        : chr  "https://cloud.r-project.org/" "http://mirror.fcaglp.unlp.edu.ar/CRAN/" "https://cran.csiro.au/" "https://mirror.aarnet.edu.au/pub/CRAN/" ...
 $ Host       : chr  "Automatic redirection to servers worldwide, currently sponsored by Rstudio" "Universidad Nacional de La Plata" "CSIRO" "AARNET" ...
 $ Maintainer : chr  "cran # rstudio.com" "esuarez # Fcaglp.unlp.edu.ar" "ben.tan # csiro.au, Jayesh.joshi # csiro.au, CSIROServiceDesk # csiro.au" "<sysadmin # aarnet.edu.au>" ...
 $ OK         : int  1 1 1 1 1 1 1 1 1 1 ...
 $ CountryCode: chr  "us" "ar" "au" "au" ...
 $ Comment    : chr  "secure_mirror_from_master" "" "secure_mirror_from_master" "secure_mirror_from_master" ...

be accepted by default (when not using a snapshot mirror)?

Suggestion 5: Add environment variable

Since the default can be quite noisy (e.g. R-hub and GitHub Actions), would it be possible to control R option BiocManager.check_repositories via a corresponding environment variable, e.g. R_BIOCMANAGER_CHECK_REPOSITORIES. That would make it possible to silence these messages from outside of R.

Dominant language
R
Stars
76
Forks
29
PR merge metrics
No merged PRs in 30d

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Bioconductor/BiocManager

All issues in Bioconductor/BiocManager

Similar issues

More R issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.