Skip to contents

Read-only preflight for reticulate selection hints. Does not load reticulate, start Python, run discovery, install software, or modify configuration.

Usage

audit_python(project = getwd(), intent = c("inspect", "managed", "existing"), expected = NULL)

Arguments

project

An existing project directory.

intent

Selection intention: inspect, managed, or existing.

expected

Optional expected interpreter file path.

Value

A retiaudit_report containing hints, markers, findings and scope. Environment values and paths are omitted.

Details

This is not an interpreter-selection prediction or dependency validation. Runtime use_python requests and delayed imports are not observed. Project startup files are not evaluated. A local virtualenv marker does not prove a valid interpreter. Guidance targets reticulate 1.41 and later.

Examples

report <- audit_python(tempdir(), intent = "managed")
report
#> # Python selection preflight
#> 
#> Intent: managed
#> reticulate: 1.47.0
#> 
#> ## Environment hints
#> 
#> | Variable | Set | Mode |
#> | --- | --- | --- |
#> | RETICULATE_PYTHON | FALSE | unset |
#> | RETICULATE_PYTHON_ENV | FALSE | unset |
#> | RETICULATE_USE_MANAGED_VENV | FALSE | unset |
#> | VIRTUAL_ENV | FALSE | unset |
#> | RETICULATE_PYTHON_FALLBACK | FALSE | unset |
#> | WORKON_HOME | FALSE | unset |
#> 
#> ## Project markers
#> 
#> | Marker | Present |
#> | --- | --- |
#> | .venv | FALSE |
#> | venv | FALSE |
#> | .virtualenv | FALSE |
#> | virtualenv | FALSE |
#> | pyproject.toml | FALSE |
#> | Pipfile | FALSE |
#> | renv.lock | FALSE |
#> | .Rprofile | FALSE |
#> | .Renviron | FALSE |
#> | r-reticulate (virtualenv root) | FALSE |
#> 
#> ## Findings
#> 
#> No visible conflict detected. This does not establish that Python will work.
#> 
#> Visible hints only. No interpreter discovery, runtime selection proof, dependency validation, or automatic fixes.
#> 
#> Local paths, environment values, startup-file contents, and package requirements are omitted. Review before sharing.