- using R version 4.4.3 (2025-02-28 ucrt)
- using platform: x86_64-w64-mingw32
- R was compiled by
gcc.exe (GCC) 13.3.0
GNU Fortran (GCC) 13.3.0
- running under: Windows Server 2022 x64 (build 20348)
- using session charset: UTF-8
- checking for file 'landscapemetrics/DESCRIPTION' ... OK
- checking extension type ... Package
- this is package 'landscapemetrics' version '2.2.1'
- package encoding: UTF-8
- checking package namespace information ... OK
- checking package dependencies ... OK
- checking if this is a source package ... OK
- checking if there is a namespace ... OK
- checking for hidden files and directories ... OK
- checking for portable file names ... OK
- checking whether package 'landscapemetrics' can be installed ... OK
See the install log for details.
- used C++ compiler: 'g++.exe (GCC) 13.3.0'
- checking installed package size ... OK
- checking package directory ... OK
- checking 'build' directory ... OK
- checking DESCRIPTION meta-information ... OK
- checking top-level files ... OK
- checking for left-over files ... OK
- checking index information ... OK
- checking package subdirectories ... OK
- checking code files for non-ASCII characters ... OK
- checking R files for syntax errors ... OK
- checking whether the package can be loaded ... [1s] OK
- checking whether the package can be loaded with stated dependencies ... [0s] OK
- checking whether the package can be unloaded cleanly ... [1s] OK
- checking whether the namespace can be loaded with stated dependencies ... [1s] OK
- checking whether the namespace can be unloaded cleanly ... [1s] OK
- checking loading without being on the library search path ... [1s] OK
- checking use of S3 registration ... OK
- checking dependencies in R code ... OK
- checking S3 generic/method consistency ... OK
- checking replacement functions ... OK
- checking foreign function calls ... OK
- checking R code for possible problems ... [19s] OK
- checking Rd files ... [4s] OK
- checking Rd metadata ... OK
- checking Rd cross-references ... OK
- checking for missing documentation entries ... OK
- checking for code/documentation mismatches ... OK
- checking Rd \usage sections ... OK
- checking Rd contents ... OK
- checking for unstated dependencies in examples ... OK
- checking contents of 'data' directory ... OK
- checking data for non-ASCII characters ... [9s] OK
- checking LazyData ... OK
- checking data for ASCII and uncompressed saves ... OK
- checking R/sysdata.rda ... OK
- checking line endings in C/C++/Fortran sources/headers ... OK
- checking pragmas in C/C++ headers and code ... OK
- checking compiled code ... OK
- checking installed files from 'inst/doc' ... OK
- checking files in 'vignettes' ... OK
- checking examples ... [10s] ERROR
Running examples in 'landscapemetrics-Ex.R' failed
The error most likely occurred in:
> ### Name: check_landscape
> ### Title: Check input landscape
> ### Aliases: check_landscape
>
> ### ** Examples
>
> augusta_nlcd <- terra::rast(landscapemetrics::augusta_nlcd)
> check_landscape(augusta_nlcd)
layer crs units class n_classes OK
1 1 projected m integer 15 ✔
> podlasie_ccilc <- terra::rast(landscapemetrics::podlasie_ccilc)
Warning: PROJ: proj_create_from_database: Cannot find proj.db (GDAL error 1)
Error: [rast] empty srs
Execution halted
- checking for unstated dependencies in 'tests' ... OK
- checking tests ... [11s] ERROR
Running 'testthat.R' [10s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
> library(testthat)
> library(landscapemetrics)
> library(terra)
terra 1.8.86
Attaching package: 'terra'
The following objects are masked from 'package:testthat':
compare, describe
>
> library(dplyr)
Attaching package: 'dplyr'
The following objects are masked from 'package:terra':
intersect, union
The following objects are masked from 'package:stats':
filter, lag
The following objects are masked from 'package:base':
intersect, setdiff, setequal, union
> library(stringr)
> library(tidyr)
Attaching package: 'tidyr'
The following object is masked from 'package:terra':
extract
>
> test_check("landscapemetrics")
Error in `source_dir()`:
! Failed to evaluate './helper-testthat.R'.
Caused by error:
! [rast] empty srs
Backtrace:
▆
1. ├─testthat::test_check("landscapemetrics")
2. │ └─testthat::test_dir(...)
3. │ └─testthat:::test_files(...)
4. │ └─testthat:::test_files_serial(...)
5. │ └─testthat:::test_files_setup_state(...)
6. │ └─testthat::source_test_helpers(".", env)
7. │ └─testthat::source_dir(path, "^helper.*\\.[rR]$", env = env, wrap = FALSE)
8. │ └─base::lapply(...)
9. │ └─testthat (local) FUN(X[[i]], ...)
10. │ └─testthat::source_file(...)
11. │ ├─base::withCallingHandlers(...)
12. │ └─base::eval(exprs, env)
13. │ └─base::eval(exprs, env)
14. │ ├─terra::rast(landscapemetrics::podlasie_ccilc) at ./helper-testthat.R:6:1
15. │ └─terra::rast(landscapemetrics::podlasie_ccilc)
16. │ └─terra (local) .local(x, ...)
17. │ ├─terra::unwrap(x)
18. │ └─terra::unwrap(x)
19. │ └─terra (local) .local(x, ...)
20. │ ├─base::eval(parse(text = x@definition))
21. │ │ └─base::eval(parse(text = x@definition))
22. │ ├─terra::rast(...)
23. │ └─terra::rast(...)
24. │ └─terra (local) .local(x = x, ...)
25. │ └─terra:::new_rast(...)
26. │ └─terra:::messages(r, "rast")
27. │ └─terra:::error(f, x@pntr$getError())
28. │ └─base::stop("[", f, "] ", emsg, ..., call. = FALSE)
29. └─base::.handleSimpleError(`<fn>`, "[rast] empty srs", base::quote(NULL))
30. └─testthat (local) h(simpleError(msg, call))
31. └─cli::cli_abort(...)
32. └─rlang::abort(...)
Warning message:
PROJ: proj_create_from_database: Cannot find proj.db (GDAL error 1)
Execution halted
- checking for unstated dependencies in vignettes ... OK
- checking package vignettes ... OK
- checking re-building of vignette outputs ... [10s] ERROR
Error(s) in re-building vignettes:
--- re-building 'get_started.Rmd' using rmarkdown
Quitting from get_started.Rmd:20-29 [load_libraries_hidden]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
<error/rlang_error>
Error:
! [rast] empty srs
---
Backtrace:
▆
1. ├─terra::rast(landscapemetrics::podlasie_ccilc)
2. └─terra::rast(landscapemetrics::podlasie_ccilc)
3. └─terra (local) .local(x, ...)
4. ├─terra::unwrap(x)
5. └─terra::unwrap(x)
6. └─terra (local) .local(x, ...)
7. ├─base::eval(parse(text = x@definition))
8. │ └─base::eval(parse(text = x@definition))
9. ├─terra::rast(...)
10. └─terra::rast(...)
11. └─terra (local) .local(x = x, ...)
12. └─terra:::new_rast(...)
13. └─terra:::messages(r, "rast")
14. └─terra:::error(f, x@pntr$getError())
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Error: processing vignette 'get_started.Rmd' failed with diagnostics:
[rast] empty srs
--- failed re-building 'get_started.Rmd'
SUMMARY: processing the following file failed:
'get_started.Rmd'
Error: Vignette re-building failed.
Execution halted
- checking PDF version of manual ... [28s] OK
- checking HTML version of manual ... [35s] OK
- DONE
Status: 3 ERRORs