tests fail

Open
#419 11 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
cpp, r

Research direction

Start with 00check.log and reproduce the R CMD check on the reported FreeBSD and R 4.4.2 environment. Inspect the failing FAQ.Rmd, cpp11.Rmd, and motivations.Rmd vignette runs; done means all three complete without missing-function errors and the check no longer reports an ERROR.

Written by the indexing model from the issue text.

Description

Trying to find if a missing dependency is causing testunit to fail.
Tested on 0.5.0 and 0.5.1.

Any clues?

Thanks

> sessionInfo()
R version 4.4.2 (2024-10-31)
Platform: amd64-portbld-freebsd15.0
Running under: FreeBSD 15amd64-main 15.0-CURRENT FreeBSD 15.0-CURRENT 1500028 amd64

Matrix products: default
LAPACK: /usr/local/lib/R/lib/libRlapack.so;  LAPACK version 3.12.0

locale:
[1] C.UTF-8/C.UTF-8/C.UTF-8/C/C.UTF-8/C.UTF-8

time zone: Europe/Lisbon
tzcode source: system (FreeBSD)

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

loaded via a namespace (and not attached):
[1] compiler_4.4.2
<snip>
* checking examples ... OK
* checking for unstated dependencies in 'tests' ... OK
* checking tests ...
 OK
* checking for unstated dependencies in vignettes ... OK
* checking package vignettes ... OK
* checking running R code from vignettes ...
  'FAQ.Rmd' using 'UTF-8'... failed
  'converting.Rmd' using 'UTF-8'... OK
  'cpp11.Rmd' using 'UTF-8'... failed
  'internals.Rmd' using 'UTF-8'... OK
  'motivations.Rmd' using 'UTF-8'... failed
 ERROR
Errors in running code in vignettes:
when running code in 'FAQ.Rmd'
  ...

> add_some <- function(x, amount = 1) {
+     add_some_(x, amount)
+ }

> add_some(1)

  When sourcing 'FAQ.R':
Error: could not find function "add_some_"
Execution halted
when running code in 'cpp11.Rmd'
  ...
> 600/(0.005 - 0.002)
[1] 2e+05

> mod <- lm(mpg ~ wt, data = mtcars)

> mpe(mod)

  When sourcing 'cpp11.R':
Error: could not find function "mpe"
Execution halted
when running code in 'motivations.Rmd'
  ...
[1] 2 4 6

> x
[1] 1 2 3

> z <- times_two_rcpp(x)

  When sourcing 'motivations.R':
Error: could not find function "times_two_rcpp"
Execution halted

* checking re-building of vignette outputs ... SKIPPED
* DONE
Status: 1 ERROR, 1 NOTE
*** Error code 1

Full log:
00check.log

Dominant language
C++
Stars
224
Forks
52
PR merge metrics
No merged PRs in 30d

Contributor guide

Open the contributing guide

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 r-lib/cpp11

All issues in r-lib/cpp11

Similar issues

More C++ issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.