Skip to contents

Use this function when debugging package loading issues, preparing reproducibility reports, or diagnosing dependency mismatches between development and production environments. The output is designed for quick visual inspection during debugging or programmatic access via the returned list for CI/CD integration.

Automatically detects the active package context (development via devtools::load_all() or installed namespace) and reports installed versions of GitHub dependencies.

Usage

describe_env(quiet = FALSE)

Arguments

quiet

Logical. Whether to suppress console output. Default FALSE prints a formatted summary to the console. Set TRUE for programmatic use where you only need the returned list (e.g., in CI pipelines or automated reports).

Value

Invisibly returns a named list with:

  • pkg_name – resolved package name (development or production)

  • pkg_desc – DESCRIPTION fields for the active package (if found)

  • env_vars – filtered non-sensitive environment variables

  • deps_github – character vector of owner/repo[@ref] from Remotes

  • deps_versions – named character vector of installed versions for GitHub deps

  • sys_info – list of R/OS/session info

Details

Sensitive variable names containing "KEY", "TOKEN", "SECRET", "PASS", "PWD", "CRED", "AUTH", "PRIVATE", or "API" (case-insensitive) are masked from the printed list to prevent accidental credential exposure in logs or screenshots.

See also

Examples

if (FALSE) { # \dontrun{
arthelpers::describe_env()

# Programmatic use without console output
env_info <- arthelpers::describe_env(quiet = TRUE)
} # }