Run python scripts from any dbt project. This project is based on the project https://github.com/fal-ai/fal initially authored by FAL.AI.
Project description
Welcome to dbt-postgres-python 👋 do more with dbt
dbt-postgres-python adapter is the ✨easiest✨ way to run your dbt Python models.
Starting with dbt v1.3, you can now build your dbt models in Python. This leads to some cool use cases that was once difficult to build with SQL alone. Some examples are:
- Using Python stats libraries to calculate stats
- Building forecasts
- Building other predictive models such as classification and clustering
This is fantastic! BUT, there is still one issue though! There is no Python support for Postgres.
dbt-postgres-python provides the best environment to run your Python models that works with Postgres! With dbt-postgres-python, you can:
- Build and test your models locally
- Isolate each model to run in its own environment with its own dependencies
NB: This project is based off the archived dbt-fal project, which initially supported other platforms. This project will only support the postgres adaptor. Support for the FAL CLI is dropped as well.
Getting Started
1. Install dbt-postgres-python
pip install dbt-postgres-python
2. Update your profiles.yml
and add the fal adapter
jaffle_shop:
target: dev_with_fal
outputs:
dev_with_fal:
type: fal # "fal" type is kept for backwards compatibility
db_profile: dev_postgres # This points to your main adapter
dev_postgres:
type: postgres
...
Don't forget to point to your main adapter with the db_profile
attribute. This is how the fal adapter knows how to connect to your data warehouse.
3. dbt run
!
That is it! It is really that simple 😊
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for dbt_postgres_python-1.5.9.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | fa8c599d4433c72a9ad0b2f62b2d58c8cb07ff089e556f39d743f30519c1215f |
|
MD5 | 8f210c85a4d6cc650092aa76cd40fe45 |
|
BLAKE2b-256 | 573e3abaf53cc02d8d20250259217ea89645f3da7516b684398585cd1c5b7c9c |
Hashes for dbt_postgres_python-1.5.9-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5f3cf48214b9780358e4e7167678595e42fa9779ade7e694d979e779e4e00b5e |
|
MD5 | aa44e60fae467120681fb4e8d031d3b1 |
|
BLAKE2b-256 | dc89687dc32f3d0f414718c84acada31e35186a60fb15882db9dd3c3d38ca21a |