* using log directory 'd:/Rcompile/CRANpkg/local/4.4/viewscape.Rcheck' * 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 'viewscape/DESCRIPTION' ... OK * checking extension type ... Package * this is package 'viewscape' version '2.0.2' * 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 'viewscape' can be installed ... OK * 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 ... [9s] OK * checking whether the package can be loaded with stated dependencies ... [9s] OK * checking whether the package can be unloaded cleanly ... [9s] OK * checking whether the namespace can be loaded with stated dependencies ... [9s] OK * checking whether the namespace can be unloaded cleanly ... [10s] OK * checking loading without being on the library search path ... [10s] OK * checking whether startup messages can be suppressed ... [10s] 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 ... [21s] OK * checking Rd files ... [1s] 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 line endings in C/C++/Fortran sources/headers ... OK * checking use of PKG_*FLAGS in Makefiles ... 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 ... [17s] ERROR Running examples in 'viewscape-Ex.R' failed The error most likely occurred in: > ### Name: calculate_feature > ### Title: calculate_feature > ### Aliases: calculate_feature > > ### ** Examples > > library(viewscape) > # Load a viewpoint > test_viewpoint <- sf::read_sf(system.file("test_viewpoint.shp", package = "viewscape")) > # load dsm raster > dsm <- terra::rast(system.file("test_dsm.tif", package ="viewscape")) > #Compute viewshed > viewshed <- viewscape::compute_viewshed(dsm = dsm, + viewpoints = test_viewpoint, + offset_viewpoint = 6) > # load canopy raster > test_canopy <- terra::rast(system.file("test_canopy.tif", + package ="viewscape")) > # calculate the percentage of canopy coverage > test_canopy_proportion <- viewscape::calculate_feature(viewshed = viewshed, + feature = test_canopy, + type = 2, + exclude_value = 0) Warning: Cannot find coordinate operations from `{ "$schema": "https://proj.org/schemas/v0.7/projjson.schema.json", "type": "EngineeringCRS", "name": "NAD83 / Michigan South (ft)", "datum": { "name": "Unknown engineering datum" }, "coordinate_system": { "subtype": "Cartesian", "axis": [ { "name": "Easting", "abbreviation": "E", "direction": "east", "unit": "metre" }, { "name": "Northing", "abbreviation": "N", "direction": "north", "unit": "metre" } ] } }' to `{ "$schema": "https://proj.org/schemas/v0.7/projjson.schema.json", "type": "ProjectedCRS", "name": "unknown", "base_crs": { "name": "unknown", "datum": { "type": "GeodeticReferenceFrame", "name": "North American Datum 1983", "ellipsoid": { "name": "GRS 1980", "semi_major_axis": 6378137, "inverse_flattening": 298.257222101 }, "id": { "authority": " [... truncated] Error: [project] cannot get output boundaries for the target crs Execution halted * checking for unstated dependencies in 'tests' ... OK * checking tests ... [28s] ERROR Running 'testthat.R' [27s] Running the tests in 'tests/testthat.R' failed. Complete output: > library(testthat) > library(viewscape) > > testthat::test_check("viewscape") Saving _problems/test-calculate_feature-25.R Saving _problems/test-calculate_viewmetrics-32.R [ FAIL 2 | WARN 3 | SKIP 0 | PASS 5 ] ══ Failed tests ════════════════════════════════════════════════════════════════ ── Error ('test-calculate_feature.R:22:3'): runs correctly ───────────────────── Error: [project] cannot get output boundaries for the target crs Backtrace: ▆ 1. └─viewscape::calculate_feature(...) at test-calculate_feature.R:22:3 2. ├─terra::project(feature, y = terra::crs(viewshed@crs)) 3. └─terra::project(feature, y = terra::crs(viewshed@crs)) 4. └─terra (local) .local(x, ...) 5. └─terra:::messages(x, "project") 6. └─terra:::error(f, x@pntr$getError()) ── Error ('test-calculate_viewmetrics.R:29:3'): runs correctly ───────────────── Error: [project] cannot get output boundaries for the target crs Backtrace: ▆ 1. └─viewscape::calculate_viewmetrics(...) at test-calculate_viewmetrics.R:29:3 2. ├─terra::project(dtm, y = terra::crs(viewshed@crs)) 3. └─terra::project(dtm, y = terra::crs(viewshed@crs)) 4. └─terra (local) .local(x, ...) 5. └─terra:::messages(x, "project") 6. └─terra:::error(f, x@pntr$getError()) [ FAIL 2 | WARN 3 | SKIP 0 | PASS 5 ] Error: ! Test failures. Execution halted * checking for unstated dependencies in vignettes ... OK * checking package vignettes ... OK * checking re-building of vignette outputs ... [3s] OK * checking PDF version of manual ... [18s] OK * checking HTML version of manual ... [2s] OK * DONE Status: 2 ERRORs