The CRAN check results in your R terminal.
foggy conditions by warning of potential hazards ahead.
foghorn makes accessible to the R terminal the CRAN check results for
packages maintained by individuals, or for other packages of interest.
The results are presented as a colored summary, or as a tibble. The
function that generates the summary is designed to be called from your
.Rprofile so you can check on the status of the packages regularly.
As new features are introduced in development versions of R, or new
policies are put in place, packages that are not updated frequently may
start generating warnings or errors when checked on CRAN’s
foghorn brings this information to your terminal so
you don’t have to leave the comfort of your R session to know the
results of the CRAN checks for your packages.
You can install the development version of
foghorn from github
or the stable version from CRAN:
## load the packagelibrary(foghorn)
foghorn provides the results of the package CRAN checks. As a
maintainer, you can easily get the results of the checks for your
packages by using the email address included in the
of your packages.
summary_cran_results() provides you with a graphical summary of the
results of the CRAN checks. The number in parenthesis after the name of
the package indicates the number of platforms used by CRAN that produced
## Graphical interfacesummary_cran_results(email = "[email protected]")#> ✔ All clear for foghorn, phylobase, riceware!#> ⚠ Packages with warnings on CRAN:#> - rncl (2)#> - rotl (3)#> ★ Package with notes on CRAN:#> - rncl (3)
summary_cran_results() is actually an alias of
summary(cran_results()), meaning that you can call
directly if you want to easily access the underlying data for the
results of the CRAN checks. These results are stored in a tibble.
## Results of the checks as a tibblecran_results(email = "[email protected]")#> # A tibble: 5 x 7#> package error fail warn note ok has_other_issues#> <chr> <int> <int> <int> <int> <int> <lgl>#> 1 foghorn 0 0 0 0 12 FALSE#> 2 phylobase 0 0 0 0 12 FALSE#> 3 riceware 0 0 0 0 12 FALSE#> 4 rncl 0 0 2 3 7 FALSE#> 5 rotl 0 0 3 0 9 FALSE
In addition of your own packages, you can also check the results for any other packages that might be of interest to you:
## either by themselvessummary_cran_results(pkg = c("ggplot2", "dplyr"))#> ⚠ Package with warnings on CRAN:#> - ggplot2 (3)#> ★ Packages with notes on CRAN:#> - dplyr (8)#> - ggplot2 (5)cran_results(pkg = c("ggplot2", "dplyr"))#> # A tibble: 2 x 7#> package error fail warn note ok has_other_issues#> <chr> <int> <int> <int> <int> <int> <lgl>#> 1 dplyr 0 0 0 8 4 FALSE#> 2 ggplot2 0 0 3 5 4 FALSE## or by combining them with email addressessummary_cran_results(email = "[email protected]",pkg = c("mregions", "ridigbio"))#> ✔ All clear for foghorn, mregions, phylobase, riceware, ridigbio!#> ⚠ Packages with warnings on CRAN:#> - rncl (2)#> - rotl (3)#> ★ Package with notes on CRAN:#> - rncl (3)cran_results(email = "[email protected]",pkg = c("mregions", "ridigbio"))#> # A tibble: 7 x 7#> package error fail warn note ok has_other_issues#> <chr> <int> <int> <int> <int> <int> <lgl>#> 1 foghorn 0 0 0 0 12 FALSE#> 2 mregions 0 0 0 0 12 FALSE#> 3 phylobase 0 0 0 0 12 FALSE#> 4 riceware 0 0 0 0 12 FALSE#> 5 ridigbio 0 0 0 0 12 FALSE#> 6 rncl 0 0 2 3 7 FALSE#> 7 rotl 0 0 3 0 9 FALSE
You can inspect the logs for the check results using
visit_cran_check(pkg) takes you directly to the CRAN webpage.
(tidyr_checks <- cran_details(pkg = "tidyr"))#> # A tibble: 1 x 7#> package version result check flavors n_flavors message#> <chr> <chr> <chr> <chr> <chr> <dbl> <chr>#> 1 tidyr 0.8.2 NOTE data for… r-devel-linux-x8… 5 " Note:…summary(tidyr_checks)#> ★ tidyr - note: data for non-ASCII characters#> ❯ r-devel-linux-x86_64-fedora-clang#> ❯ r-devel-linux-x86_64-fedora-gcc#> ❯ r-patched-solaris-x86#> ❯ r-release-osx-x86_64#> ❯ r-oldrel-osx-x86_64#>#> Note: found 23 marked UTF-8 strings
The data from the check results used by this package are either scraped
from the CRAN web pages (default), or are from the CRAN database (that
CRAN uses to build the webpages). The first option is faster if you want
to regularly check a few packages. However, if you are doing statistics
on a large number of packages, using the CRAN database is recommended
(it’s about 20Mb of data). To use the CRAN database, add
src = "crandb" in your function calls:
cran_results(pkg = "nlme", src = "crandb")#> # A tibble: 1 x 7#> package error fail warn note ok has_other_issues#> <chr> <int> <int> <int> <int> <int> <lgl>#> 1 nlme 0 0 0 0 12 FALSE
Check out the “Details” section in the help files for more information.
Feel free to submit feedback and suggestions by opening an issue on GitHub.
Please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms.
cran_incomingnow includes the date/time (contribution by @bbolker, #30)
foghornrespects the CRAN mirror set by the users instead of using
foghornwill retry up to three times.
foghornwould, in some cases, return that a valid package name published on CRAN did not exit (#29, @zkamvar).
newbiesfolder found on the CRAN FTP incoming server has been added to the list of places to check packages in CRAN's submisison queue (#32).
noemailfolder has been removed from the CRAN FTP incoming server.
cran_incoming()has been updated to reflect this change.
foghornhas an hex logo. Thanks to Maëlle Salmon for feedback on initial design.
cran_incoming() to retrieve the list of packages currently in the CRAN
incoming queue. Feature requested by @krlmlr, #24.
foghorn is now compatible with R >= 3.1. Suggested by @jimhester, #26.
show_cran_results()are deprecated in favor of
Add initial support for https://cranchecks.info as a data source (not exported/tested at this stage).
Take into consideration issues other than memtest when parsing the HTML CRAN check page.
summary() method for
cran_results that can
optionally print an "all clear" message when all CRAN checks return "OK" for a
A progress bar is displayed when the RDS files are being downloaded from CRAN if the progress package is installed (#17).
The version number of the packages are displayed in
All the functions return tibbles, with column names in lower case.
Fix bug #14 reported by @hadley, no issues are now represented as 0 instead of
Fix bug that would display a number instead of the package name in some situations.