dm icon indicating copy to clipboard operation
dm copied to clipboard

dm incompatible with pkgdown in a package that imports dm

Open MatthewHeun opened this issue 1 year ago • 1 comments

Steps to reproduce:

  • Use RStudio to start a new project of type package in an empty folder. I created the empty folder at ~/Desktop/testdmpkgdown/ like this: image

  • Add the line "Imports: dm" to the DESCRIPTION file

  • Install the package (Build|Install Package)

  • Type "pkgdown:::build_site_external()" in the console (Or choose "Build pkgdown" from the Addins menu)

Expected result:

  • Browser window opens with a (very rudimentary) pkgdown site for the new package

Actual result:

Error: 
! in callr subprocess.
Caused by error in `load_imports(path)`:
! 
ℹ See `$stdout` for standard output.
Type .Last.error to see the more details.

Here is the output from .Last.error:

<callr_error/rlib_error_3_0/rlib_error/error>
Error: 
! in callr subprocess.
Caused by error in `load_imports(path)`:
! 
ℹ See `$stdout` for standard output.
---
Backtrace:
1. pkgdown:::build_site_external()
2. callr::r(function(..., cli_colors, pkgdown_internet) { …
3. callr:::get_result(output = out, options)
4. callr:::throw(callr_remote_error(remerr, output), parent = fix_msg(remerr[[3]]))
---
Subprocess backtrace:
 1. pkgdown::build_site(...)
 2. pkgdown:::build_site_local(pkg = pkg, examples = examples, run_dont_run = run_dont_run, …
 3. pkgdown::build_reference(pkg, lazy = lazy, examples = examples, run_dont_run = run_dont_…
 4. pkgdown:::examples_env(pkg, seed = seed, devel = devel)
 5. pkgload::load_all(pkg$src_path, export_all = FALSE, helpers = FALSE, …
 6. pkgload:::load_imports(path)
 7. pkgload:::deps_check_installed(path, imports)
 8. rlang::check_installed(pkg, action = action, call = call)
 9. base::stop(cnd)
10. global (function (e) …

Impact:

  • This issue prevents constructing pkgdown documentation websites for packages that Imports: dm.

Workarounds:

  • None known at this time.

Additional information:

  • All other imported packages that I tried work correctly. For example,
    • "Imports: magrittr" works
    • "Imports: stringi" works
  • Any time "dm" is included in the Imports: field, the error occurs.
    • "Imports: magrittr, dm" fails
    • "Imports: stringi, dm" fails

Machine, OS, etc:

  • macOS Sonoma 14.1.1
  • R 4.3.2
  • RStudio 2023.12.1+402
  • dm 1.0.10
  • pkgdown 2.0.7

MatthewHeun avatar Feb 16 '24 20:02 MatthewHeun

Thanks, this is weird.

@dickoa @josesamos: You have packages that import dm. Can you build pkgdown sites for these packages?

krlmlr avatar Nov 24 '24 21:11 krlmlr