Skip to contents

Python is only involved when extract_lineage() analyzes raw SQL strings or duckplyr frames (or falls back to sqlglot for a dbplyr pipeline it cannot trace in R); dbplyr, dtplyr, and arrow pipelines are analyzed by pure-R engines. The sqlglot engine needs the reticulate package (a Suggests dependency; install it with install.packages("reticulate")); dplyneage then declares its sqlglot dependency via reticulate::py_require(), so sqlglot itself is provisioned automatically the first time it is needed. Use this to check availability, or to gate code that needs the sqlglot engine (examples, vignette chunks, Shiny apps). Returns FALSE when reticulate is not installed. Note that calling it may initialize Python.

Usage

has_sqlglot()

Value

TRUE if sqlglot can be loaded, FALSE otherwise

See also

vignette("python-integration") for using your own Python environment

Examples

has_sqlglot()
#> [1] TRUE